WooCommerce Services - Version 1.22.4

Version Description

  • 2020-03-02 =
  • Fix - Stop using deprecated method Jetpack::is_staging_site() when Jetpack 8.1 is installed.
Download this release

Release Info

Developer ferdev
Plugin Icon 128x128 WooCommerce Services
Version 1.22.4
Comparing to
See all releases

Code changes from version 1.22.3 to 1.22.4

Files changed (58) hide show
  1. classes/class-wc-connect-jetpack.php +4 -0
  2. dist/{woocommerce-services-1.22.3.css → woocommerce-services-1.22.4.css} +0 -0
  3. dist/{woocommerce-services-1.22.3.js → woocommerce-services-1.22.4.js} +0 -0
  4. dist/{woocommerce-services-admin-pointers-1.22.3.js → woocommerce-services-admin-pointers-1.22.4.js} +0 -0
  5. dist/{woocommerce-services-banner-1.22.3.css → woocommerce-services-banner-1.22.4.css} +0 -0
  6. dist/{woocommerce-services-banner-1.22.3.js → woocommerce-services-banner-1.22.4.js} +0 -0
  7. dist/{woocommerce-services-new-order-taxjar-1.22.3.js → woocommerce-services-new-order-taxjar-1.22.4.js} +0 -0
  8. i18n/languages/woocommerce-services.pot +258 -258
  9. i18n/strings.php +290 -290
  10. readme.txt +5 -1
  11. trunk/classes/class-wc-connect-api-client.php +682 -0
  12. trunk/classes/class-wc-connect-compatibility-wc26.php +146 -0
  13. trunk/classes/class-wc-connect-compatibility-wc30.php +172 -0
  14. trunk/classes/class-wc-connect-compatibility.php +151 -0
  15. trunk/classes/class-wc-connect-debug-tools.php +38 -0
  16. trunk/classes/class-wc-connect-error-notice.php +111 -0
  17. trunk/classes/class-wc-connect-extension-compatibility.php +41 -0
  18. trunk/classes/class-wc-connect-functions.php +23 -0
  19. trunk/classes/class-wc-connect-help-view.php +345 -0
  20. trunk/classes/class-wc-connect-jetpack.php +112 -0
  21. trunk/classes/class-wc-connect-label-reports.php +224 -0
  22. trunk/classes/class-wc-connect-logger.php +135 -0
  23. trunk/classes/class-wc-connect-nux.php +715 -0
  24. trunk/classes/class-wc-connect-options.php +341 -0
  25. trunk/classes/class-wc-connect-payment-gateway.php +20 -0
  26. trunk/classes/class-wc-connect-payment-methods-store.php +119 -0
  27. trunk/classes/class-wc-connect-paypal-ec.php +342 -0
  28. trunk/classes/class-wc-connect-privacy.php +118 -0
  29. trunk/classes/class-wc-connect-service-schemas-store.php +250 -0
  30. trunk/classes/class-wc-connect-service-schemas-validator.php +195 -0
  31. trunk/classes/class-wc-connect-service-settings-store.php +584 -0
  32. trunk/classes/class-wc-connect-settings-pages.php +80 -0
  33. trunk/classes/class-wc-connect-shipping-label.php +408 -0
  34. trunk/classes/class-wc-connect-shipping-method.php +636 -0
  35. trunk/classes/class-wc-connect-stripe.php +404 -0
  36. trunk/classes/class-wc-connect-taxjar-integration.php +1163 -0
  37. trunk/classes/class-wc-connect-tracks.php +125 -0
  38. trunk/classes/class-wc-rest-connect-account-settings-controller.php +101 -0
  39. trunk/classes/class-wc-rest-connect-address-normalization-controller.php +70 -0
  40. trunk/classes/class-wc-rest-connect-base-controller.php +110 -0
  41. trunk/classes/class-wc-rest-connect-packages-controller.php +48 -0
  42. trunk/classes/class-wc-rest-connect-self-help-controller.php +45 -0
  43. trunk/classes/class-wc-rest-connect-services-controller.php +94 -0
  44. trunk/classes/class-wc-rest-connect-shipping-label-controller.php +133 -0
  45. trunk/classes/class-wc-rest-connect-shipping-label-preview-controller.php +40 -0
  46. trunk/classes/class-wc-rest-connect-shipping-label-print-controller.php +69 -0
  47. trunk/classes/class-wc-rest-connect-shipping-label-refund-controller.php +45 -0
  48. trunk/classes/class-wc-rest-connect-shipping-label-status-controller.php +35 -0
  49. trunk/classes/class-wc-rest-connect-shipping-rates-controller.php +169 -0
  50. trunk/classes/class-wc-rest-connect-stripe-account-controller.php +60 -0
  51. trunk/classes/class-wc-rest-connect-stripe-deauthorize-controller.php +40 -0
  52. trunk/classes/class-wc-rest-connect-stripe-oauth-connect-controller.php +42 -0
  53. trunk/classes/class-wc-rest-connect-stripe-oauth-init-controller.php +41 -0
  54. trunk/classes/class-wc-rest-connect-tos-controller.php +45 -0
  55. trunk/classes/wc-api-dev/class-wc-rest-dev-data-continents-controller.php +357 -0
  56. trunk/classes/wc-api-dev/class-wc-rest-dev-data-controller.php +188 -0
  57. trunk/dist/woocommerce-services-1.22.4.css +20 -0
  58. trunk/dist/woocommerce-services-1.22.4.js +7 -0
classes/class-wc-connect-jetpack.php CHANGED
@@ -31,6 +31,10 @@ if ( ! class_exists( 'WC_Connect_Jetpack' ) ) {
31
  * @return bool
32
  */
33
  public static function is_staging_site() {
 
 
 
 
34
  if ( method_exists( 'Jetpack', 'is_staging_site' ) ) {
35
  return Jetpack::is_staging_site();
36
  }
31
  * @return bool
32
  */
33
  public static function is_staging_site() {
34
+ if ( method_exists( '\\Automattic\\Jetpack\\Status', 'is_staging_site' ) ) {
35
+ return ( new \Automattic\Jetpack\Status )->is_staging_site();
36
+ }
37
+
38
  if ( method_exists( 'Jetpack', 'is_staging_site' ) ) {
39
  return Jetpack::is_staging_site();
40
  }
dist/{woocommerce-services-1.22.3.css → woocommerce-services-1.22.4.css} RENAMED
File without changes
dist/{woocommerce-services-1.22.3.js → woocommerce-services-1.22.4.js} RENAMED
File without changes
dist/{woocommerce-services-admin-pointers-1.22.3.js → woocommerce-services-admin-pointers-1.22.4.js} RENAMED
File without changes
dist/{woocommerce-services-banner-1.22.3.css → woocommerce-services-banner-1.22.4.css} RENAMED
File without changes
dist/{woocommerce-services-banner-1.22.3.js → woocommerce-services-banner-1.22.4.js} RENAMED
File without changes
dist/{woocommerce-services-new-order-taxjar-1.22.3.js → woocommerce-services-new-order-taxjar-1.22.4.js} RENAMED
File without changes
i18n/languages/woocommerce-services.pot CHANGED
@@ -4,7 +4,7 @@ msgid ""
4
  msgstr ""
5
  "Project-Id-Version: _s woocommerce-services\n"
6
  "Report-Msgid-Bugs-To: \n"
7
- "POT-Creation-Date: 2020-01-22T19:00:07.165Z\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
@@ -12,1093 +12,1093 @@ msgstr ""
12
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13
  "Language-Team: LANGUAGE <LL@li.org>\n"
14
 
15
- #: dist/woocommerce-services-1.22.3.js:107
16
  msgid "Dismiss"
17
  msgstr ""
18
 
19
- #: dist/woocommerce-services-1.22.3.js:107
20
  msgid "Required"
21
  msgstr ""
22
 
23
- #: dist/woocommerce-services-1.22.3.js:107
24
  msgid "Optional"
25
  msgstr ""
26
 
27
- #: dist/woocommerce-services-1.22.3.js:107
28
  msgid "More"
29
  msgstr ""
30
 
31
- #: dist/woocommerce-services-1.22.3.js:107
32
  msgid "All services selected"
33
  msgstr ""
34
 
35
- #: dist/woocommerce-services-1.22.3.js:107
36
  msgid "%(numSelected)d service selected"
37
  msgid_plural "%(numSelected)d services selected"
38
  msgstr[0] ""
39
  msgstr[1] ""
40
 
41
- #: dist/woocommerce-services-1.22.3.js:107
42
  msgid "Expand Services"
43
  msgstr ""
44
 
45
- #: dist/woocommerce-services-1.22.3.js:107
46
  msgid "Service"
47
  msgstr ""
48
 
49
- #: dist/woocommerce-services-1.22.3.js:107
50
  msgid "Price adjustment"
51
  msgstr ""
52
 
53
- #: dist/woocommerce-services-1.22.3.js:107
54
  msgid ""
55
  "Increase the rates calculated by the carrier to account for packaging and "
56
  "handling costs. You can also add a negative amount to save your customers "
57
  "money."
58
  msgstr ""
59
 
60
- #: dist/woocommerce-services-1.22.3.js:107
61
  msgid "Saved Packages"
62
  msgstr ""
63
 
64
- #: dist/woocommerce-services-1.22.3.js:107
65
  msgid "Add and edit saved packages using the {{a}}Packaging Manager{{/a}}."
66
  msgstr ""
67
 
68
- #: dist/woocommerce-services-1.22.3.js:107
69
  msgid "You have unsaved changes."
70
  msgstr ""
71
 
72
- #: dist/woocommerce-services-1.22.3.js:107
73
  msgid "Your changes have been saved."
74
  msgstr ""
75
 
76
- #: dist/woocommerce-services-1.22.3.js:107
77
  msgid ""
78
  "There was a problem with one or more entries. Please fix the errors below "
79
  "and try saving again."
80
  msgstr ""
81
 
82
- #: dist/woocommerce-services-1.22.3.js:107
83
  msgid "Save changes"
84
  msgstr ""
85
 
86
- #: dist/woocommerce-services-1.22.3.js:107
87
  msgid "Saving…"
88
  msgstr ""
89
 
90
- #: dist/woocommerce-services-1.22.3.js:107
91
  msgid "Save Settings"
92
  msgstr ""
93
 
94
- #: dist/woocommerce-services-1.22.3.js:107
95
  msgid ""
96
  "We have slightly modified the address entered. If correct, please use the "
97
  "suggested address to ensure accurate delivery."
98
  msgstr ""
99
 
100
- #: dist/woocommerce-services-1.22.3.js:107
101
  msgid "Address entered"
102
  msgstr ""
103
 
104
- #: dist/woocommerce-services-1.22.3.js:107
105
  msgid "Suggested address"
106
  msgstr ""
107
 
108
- #: dist/woocommerce-services-1.22.3.js:107
109
  msgid "Use selected address"
110
  msgstr ""
111
 
112
- #: dist/woocommerce-services-1.22.3.js:107
113
  msgid "Edit address"
114
  msgstr ""
115
 
116
- #: dist/woocommerce-services-1.22.3.js:107
117
  msgid "We were unable to automatically verify the address — %(error)s."
118
  msgstr ""
119
 
120
- #: dist/woocommerce-services-1.22.3.js:107
121
  msgid "We were unable to automatically verify the address."
122
  msgstr ""
123
 
124
- #: dist/woocommerce-services-1.22.3.js:107
125
  msgid ""
126
  "Automatic verification failed for this address. It may still be a valid "
127
  "address — use the tools below to manually verify."
128
  msgstr ""
129
 
130
- #: dist/woocommerce-services-1.22.3.js:107
131
  msgid "Verify with USPS"
132
  msgstr ""
133
 
134
- #: dist/woocommerce-services-1.22.3.js:107
135
  msgid "View on Google Maps"
136
  msgstr ""
137
 
138
- #: dist/woocommerce-services-1.22.3.js:107
139
  msgid "Use address as entered"
140
  msgstr ""
141
 
142
- #: dist/woocommerce-services-1.22.3.js:107
143
  msgid "Name"
144
  msgstr ""
145
 
146
- #: dist/woocommerce-services-1.22.3.js:107
147
  msgid "Company"
148
  msgstr ""
149
 
150
- #: dist/woocommerce-services-1.22.3.js:107
151
  msgid "Phone"
152
  msgstr ""
153
 
154
- #: dist/woocommerce-services-1.22.3.js:107
155
  msgid "%(message)s. Please modify the address and try again."
156
  msgstr ""
157
 
158
- #: dist/woocommerce-services-1.22.3.js:107
159
  msgid "Address"
160
  msgstr ""
161
 
162
- #: dist/woocommerce-services-1.22.3.js:107
163
  msgid "City"
164
  msgstr ""
165
 
166
- #: dist/woocommerce-services-1.22.3.js:107
167
  msgid "State"
168
  msgstr ""
169
 
170
- #: dist/woocommerce-services-1.22.3.js:107
171
  msgid "Select one…"
172
  msgstr ""
173
 
174
- #: dist/woocommerce-services-1.22.3.js:107
175
  msgid "Postal code"
176
  msgstr ""
177
 
178
- #: dist/woocommerce-services-1.22.3.js:107
179
  msgid "Country"
180
  msgstr ""
181
 
182
- #: dist/woocommerce-services-1.22.3.js:107
183
  msgid "Verify address"
184
  msgstr ""
185
 
186
- #: dist/woocommerce-services-1.22.3.js:107
187
  msgid "Expand"
188
  msgstr ""
189
 
190
- #: dist/woocommerce-services-1.22.3.js:107
191
  msgid "Validating address…"
192
  msgstr ""
193
 
194
- #: dist/woocommerce-services-1.22.3.js:107
195
  msgid "Invalid address"
196
  msgstr ""
197
 
198
- #: dist/woocommerce-services-1.22.3.js:107
199
  msgid "You've edited the address, please revalidate it for accurate rates"
200
  msgstr ""
201
 
202
- #: dist/woocommerce-services-1.22.3.js:107
203
  msgid "Packages to be Shipped"
204
  msgstr ""
205
 
206
- #: dist/woocommerce-services-1.22.3.js:107
207
  msgid "Move"
208
  msgstr ""
209
 
210
- #: dist/woocommerce-services-1.22.3.js:107
211
  #. Length placeholder for dimensions input
212
  msgid "L"
213
  msgstr ""
214
 
215
- #: dist/woocommerce-services-1.22.3.js:107
216
  #. Width placeholder for dimensions input
217
  msgid "W"
218
  msgstr ""
219
 
220
- #: dist/woocommerce-services-1.22.3.js:107
221
  #. Height placeholder for dimensions input
222
  msgid "H"
223
  msgstr ""
224
 
225
- #: dist/woocommerce-services-1.22.3.js:107
226
  msgid "Invalid value."
227
  msgstr ""
228
 
229
- #: dist/woocommerce-services-1.22.3.js:107
230
  msgid "This field is required."
231
  msgstr ""
232
 
233
- #: dist/woocommerce-services-1.22.3.js:107
234
  msgid "Type of package"
235
  msgstr ""
236
 
237
- #: dist/woocommerce-services-1.22.3.js:107
238
  msgid "Box"
239
  msgstr ""
240
 
241
- #: dist/woocommerce-services-1.22.3.js:107
242
  msgid "Envelope"
243
  msgstr ""
244
 
245
- #: dist/woocommerce-services-1.22.3.js:107
246
  msgid "Package name"
247
  msgstr ""
248
 
249
- #: dist/woocommerce-services-1.22.3.js:107
250
  msgid "Unique package name"
251
  msgstr ""
252
 
253
- #: dist/woocommerce-services-1.22.3.js:107
254
  msgid "This field must be unique"
255
  msgstr ""
256
 
257
- #: dist/woocommerce-services-1.22.3.js:107
258
  msgid "Dimensions (L x W x H)"
259
  msgstr ""
260
 
261
- #: dist/woocommerce-services-1.22.3.js:107
262
  msgid "Weight of empty package"
263
  msgstr ""
264
 
265
- #: dist/woocommerce-services-1.22.3.js:107
266
  msgid "0.0"
267
  msgstr ""
268
 
269
- #: dist/woocommerce-services-1.22.3.js:107
270
  msgid "Untitled"
271
  msgstr ""
272
 
273
- #: dist/woocommerce-services-1.22.3.js:107
274
  msgid "All packages selected"
275
  msgstr ""
276
 
277
- #: dist/woocommerce-services-1.22.3.js:107
278
  msgid "%(selectedCount)d package selected"
279
  msgid_plural "%(selectedCount)d packages selected"
280
  msgstr[0] ""
281
  msgstr[1] ""
282
 
283
- #: dist/woocommerce-services-1.22.3.js:107
284
  msgid "Your shipping packages have been saved."
285
  msgstr ""
286
 
287
- #: dist/woocommerce-services-1.22.3.js:107
288
  msgid "Unable to save your shipping packages. Please try again."
289
  msgstr ""
290
 
291
- #: dist/woocommerce-services-1.22.3.js:107
292
  msgid "Add package"
293
  msgid_plural "Add packages"
294
  msgstr[0] ""
295
  msgstr[1] ""
296
 
297
- #: dist/woocommerce-services-1.22.3.js:107
298
  msgid "Done"
299
  msgstr ""
300
 
301
- #: dist/woocommerce-services-1.22.3.js:107
302
  msgid "Cancel"
303
  msgstr ""
304
 
305
- #: dist/woocommerce-services-1.22.3.js:107
306
  msgid "{{icon/}} Delete this package"
307
  msgstr ""
308
 
309
- #: dist/woocommerce-services-1.22.3.js:107
310
  msgid "Individually Shipped Item"
311
  msgstr ""
312
 
313
- #: dist/woocommerce-services-1.22.3.js:107
314
  msgid "Item Dimensions"
315
  msgstr ""
316
 
317
- #: dist/woocommerce-services-1.22.3.js:107
318
  msgid "Package details"
319
  msgstr ""
320
 
321
- #: dist/woocommerce-services-1.22.3.js:107
322
  msgid "Select a package type"
323
  msgstr ""
324
 
325
- #: dist/woocommerce-services-1.22.3.js:107
326
  msgid "Please select a package"
327
  msgstr ""
328
 
329
- #: dist/woocommerce-services-1.22.3.js:107
330
  msgid "Add items"
331
  msgstr ""
332
 
333
- #: dist/woocommerce-services-1.22.3.js:107
334
  msgid "Items to fulfill"
335
  msgstr ""
336
 
337
- #: dist/woocommerce-services-1.22.3.js:107
338
  msgid "Weight"
339
  msgstr ""
340
 
341
- #: dist/woocommerce-services-1.22.3.js:107
342
  msgid "QTY"
343
  msgstr ""
344
 
345
- #: dist/woocommerce-services-1.22.3.js:107
346
  msgid "There are no items in this package."
347
  msgstr ""
348
 
349
- #: dist/woocommerce-services-1.22.3.js:107
350
  msgid "Total Weight (with package)"
351
  msgstr ""
352
 
353
- #: dist/woocommerce-services-1.22.3.js:107
354
  msgid "0"
355
  msgstr ""
356
 
357
- #: dist/woocommerce-services-1.22.3.js:107
358
  msgid "{{itemLink/}} is currently saved for a later shipment."
359
  msgstr ""
360
 
361
- #: dist/woocommerce-services-1.22.3.js:107
362
  msgid "{{itemLink/}} is currently shipped in its original packaging."
363
  msgstr ""
364
 
365
- #: dist/woocommerce-services-1.22.3.js:107
366
  msgid "{{itemLink/}} is currently in {{pckg/}}."
367
  msgstr ""
368
 
369
- #: dist/woocommerce-services-1.22.3.js:107
370
  msgid "Submit"
371
  msgstr ""
372
 
373
- #: dist/woocommerce-services-1.22.3.js:107
374
  msgid "Move item"
375
  msgstr ""
376
 
377
- #: dist/woocommerce-services-1.22.3.js:107
378
  msgid "Where would you like to move it?"
379
  msgstr ""
380
 
381
- #: dist/woocommerce-services-1.22.3.js:107
382
  msgid "Add to a New Package"
383
  msgstr ""
384
 
385
- #: dist/woocommerce-services-1.22.3.js:107
386
  msgid "Ship in original packaging"
387
  msgstr ""
388
 
389
- #: dist/woocommerce-services-1.22.3.js:107
390
  msgid "Remove from package"
391
  msgstr ""
392
 
393
- #: dist/woocommerce-services-1.22.3.js:107
394
  msgid "%(item)s from {{pckg/}}"
395
  msgstr ""
396
 
397
- #: dist/woocommerce-services-1.22.3.js:107
398
  msgid "Close"
399
  msgstr ""
400
 
401
- #: dist/woocommerce-services-1.22.3.js:107
402
  msgid "Add"
403
  msgstr ""
404
 
405
- #: dist/woocommerce-services-1.22.3.js:107
406
  msgid "Add item"
407
  msgstr ""
408
 
409
- #: dist/woocommerce-services-1.22.3.js:107
410
  msgid "Which items would you like to add to {{pckg/}}?"
411
  msgstr ""
412
 
413
- #: dist/woocommerce-services-1.22.3.js:107
414
  msgid "Packaging"
415
  msgstr ""
416
 
417
- #: dist/woocommerce-services-1.22.3.js:107
418
  msgid "No packages selected"
419
  msgstr ""
420
 
421
- #: dist/woocommerce-services-1.22.3.js:107
422
  msgid "1 item in 1 package: %(weight)s %(unit)s total"
423
  msgstr ""
424
 
425
- #: dist/woocommerce-services-1.22.3.js:107
426
  msgid "%(itemsCount)d items in 1 package: %(weight)s %(unit)s total"
427
  msgstr ""
428
 
429
- #: dist/woocommerce-services-1.22.3.js:107
430
  msgid ""
431
  "%(itemsCount)d items in %(packageCount)d packages: %(weight)s %(unit)s total"
432
  msgstr ""
433
 
434
- #: dist/woocommerce-services-1.22.3.js:107
435
  msgid "Use these packages"
436
  msgstr ""
437
 
438
- #: dist/woocommerce-services-1.22.3.js:107
439
  msgid "HS Tariff number"
440
  msgstr ""
441
 
442
- #: dist/woocommerce-services-1.22.3.js:107
443
  msgid "more info"
444
  msgstr ""
445
 
446
- #: dist/woocommerce-services-1.22.3.js:107
447
  msgid "Origin country"
448
  msgstr ""
449
 
450
- #: dist/woocommerce-services-1.22.3.js:107
451
  msgid "Country where the product was manufactured or assembled"
452
  msgstr ""
453
 
454
- #: dist/woocommerce-services-1.22.3.js:107
455
  msgid "Description"
456
  msgstr ""
457
 
458
- #: dist/woocommerce-services-1.22.3.js:107
459
  msgid "Weight (%s per unit)"
460
  msgstr ""
461
 
462
- #: dist/woocommerce-services-1.22.3.js:107
463
  msgid "Value ($ per unit)"
464
  msgstr ""
465
 
466
- #: dist/woocommerce-services-1.22.3.js:107
467
  msgid "Weight (per unit)"
468
  msgstr ""
469
 
470
- #: dist/woocommerce-services-1.22.3.js:107
471
  msgid "Value (per unit)"
472
  msgstr ""
473
 
474
- #: dist/woocommerce-services-1.22.3.js:107
475
  msgid "Return to sender if package is unable to be delivered"
476
  msgstr ""
477
 
478
- #: dist/woocommerce-services-1.22.3.js:107
479
  msgid "Contents type"
480
  msgstr ""
481
 
482
- #: dist/woocommerce-services-1.22.3.js:107
483
  msgid "Merchandise"
484
  msgstr ""
485
 
486
- #: dist/woocommerce-services-1.22.3.js:107
487
  msgid "Documents"
488
  msgstr ""
489
 
490
- #: dist/woocommerce-services-1.22.3.js:107
491
  msgid "Gift"
492
  msgstr ""
493
 
494
- #: dist/woocommerce-services-1.22.3.js:107
495
  msgid "Sample"
496
  msgstr ""
497
 
498
- #: dist/woocommerce-services-1.22.3.js:107
499
  msgid "Other…"
500
  msgstr ""
501
 
502
- #: dist/woocommerce-services-1.22.3.js:107
503
  msgid "Details"
504
  msgstr ""
505
 
506
- #: dist/woocommerce-services-1.22.3.js:107
507
  msgid "Restriction type"
508
  msgstr ""
509
 
510
- #: dist/woocommerce-services-1.22.3.js:107
511
  msgid "None"
512
  msgstr ""
513
 
514
- #: dist/woocommerce-services-1.22.3.js:107
515
  msgid "Quarantine"
516
  msgstr ""
517
 
518
- #: dist/woocommerce-services-1.22.3.js:107
519
  msgid "Sanitary / Phytosanitary inspection"
520
  msgstr ""
521
 
522
- #: dist/woocommerce-services-1.22.3.js:107
523
  msgid "ITN"
524
  msgstr ""
525
 
526
- #: dist/woocommerce-services-1.22.3.js:107
527
  msgid "Customs information incomplete"
528
  msgstr ""
529
 
530
- #: dist/woocommerce-services-1.22.3.js:107
531
  msgid "Customs information valid"
532
  msgstr ""
533
 
534
- #: dist/woocommerce-services-1.22.3.js:107
535
  msgid "Customs"
536
  msgstr ""
537
 
538
- #: dist/woocommerce-services-1.22.3.js:107
539
  msgid "Save customs form"
540
  msgstr ""
541
 
542
- #: dist/woocommerce-services-1.22.3.js:107
543
  msgid ""
544
  "The service and rate chosen by the customer at checkout is not available. "
545
  "Please choose another."
546
  msgstr ""
547
 
548
- #: dist/woocommerce-services-1.22.3.js:107
549
  msgid "Choose rate: %(pckg)s"
550
  msgstr ""
551
 
552
- #: dist/woocommerce-services-1.22.3.js:107
553
  msgid "Unsaved changes made to packages"
554
  msgstr ""
555
 
556
- #: dist/woocommerce-services-1.22.3.js:107
557
  msgid "No rates found"
558
  msgstr ""
559
 
560
- #: dist/woocommerce-services-1.22.3.js:107
561
  msgid "%(serviceName)s: %(rate)s"
562
  msgstr ""
563
 
564
- #: dist/woocommerce-services-1.22.3.js:107
565
  msgid "Total rate: %(total)s"
566
  msgstr ""
567
 
568
- #: dist/woocommerce-services-1.22.3.js:107
569
  msgid "Shipping rates"
570
  msgstr ""
571
 
572
- #: dist/woocommerce-services-1.22.3.js:107
573
  msgid "Customer paid a {{shippingMethod/}} of {{shippingCost/}} for shipping"
574
  msgstr ""
575
 
576
- #: dist/woocommerce-services-1.22.3.js:107
577
  msgid "Your customer selected {{shippingMethod/}}"
578
  msgstr ""
579
 
580
- #: dist/woocommerce-services-1.22.3.js:107
581
  msgid ""
582
  "WooCommerce Services gives you access to USPS Commercial Pricing, which is "
583
  "discounted over Retail rates."
584
  msgstr ""
585
 
586
- #: dist/woocommerce-services-1.22.3.js:107
587
  msgid "Package %(index)s"
588
  msgstr ""
589
 
590
- #: dist/woocommerce-services-1.22.3.js:107
591
  msgid "You save"
592
  msgstr ""
593
 
594
- #: dist/woocommerce-services-1.22.3.js:107
595
  msgid "Total"
596
  msgstr ""
597
 
598
- #: dist/woocommerce-services-1.22.3.js:107
599
  msgid "Shipping summary"
600
  msgstr ""
601
 
602
- #: dist/woocommerce-services-1.22.3.js:107
603
  msgid "Shipping from"
604
  msgstr ""
605
 
606
- #: dist/woocommerce-services-1.22.3.js:107
607
  msgid "Edit"
608
  msgstr ""
609
 
610
- #: dist/woocommerce-services-1.22.3.js:107
611
  msgid "shipping label ready"
612
  msgid_plural "shipping labels ready"
613
  msgstr[0] ""
614
  msgstr[1] ""
615
 
616
- #: dist/woocommerce-services-1.22.3.js:107
617
  msgid "Print"
618
  msgstr ""
619
 
620
- #: dist/woocommerce-services-1.22.3.js:107
621
  msgid "Purchasing…"
622
  msgstr ""
623
 
624
- #: dist/woocommerce-services-1.22.3.js:107
625
  msgid "Buy shipping labels"
626
  msgstr ""
627
 
628
- #: dist/woocommerce-services-1.22.3.js:107
629
  msgid "Choose credit card"
630
  msgstr ""
631
 
632
- #: dist/woocommerce-services-1.22.3.js:107
633
  msgid ""
634
  "To print this shipping label, {{a}}choose a credit card to your account{{/"
635
  "a}}."
636
  msgstr ""
637
 
638
- #: dist/woocommerce-services-1.22.3.js:107
639
  msgid "Add credit card"
640
  msgstr ""
641
 
642
- #: dist/woocommerce-services-1.22.3.js:107
643
  msgid ""
644
  "To print this shipping label, {{a}}add a credit card to your account{{/a}}."
645
  msgstr ""
646
 
647
- #: dist/woocommerce-services-1.22.3.js:107
648
  msgid "Email shipment details to the customer"
649
  msgstr ""
650
 
651
- #: dist/woocommerce-services-1.22.3.js:107
652
  msgid "Mark the order as fulfilled"
653
  msgstr ""
654
 
655
- #: dist/woocommerce-services-1.22.3.js:107
656
  msgid "Paper size"
657
  msgstr ""
658
 
659
- #: dist/woocommerce-services-1.22.3.js:107
660
  msgid "Create shipping label"
661
  msgstr ""
662
 
663
- #: dist/woocommerce-services-1.22.3.js:107
664
  msgid "Create shipping labels"
665
  msgstr ""
666
 
667
- #: dist/woocommerce-services-1.22.3.js:107
668
  msgid "Origin address"
669
  msgstr ""
670
 
671
- #: dist/woocommerce-services-1.22.3.js:107
672
  msgid "Destination address"
673
  msgstr ""
674
 
675
- #: dist/woocommerce-services-1.22.3.js:107
676
  msgid "Toggle menu"
677
  msgstr ""
678
 
679
- #: dist/woocommerce-services-1.22.3.js:107
680
  msgid "Refund label (-%(amount)s)"
681
  msgstr ""
682
 
683
- #: dist/woocommerce-services-1.22.3.js:107
684
  msgid "Request a refund"
685
  msgstr ""
686
 
687
- #: dist/woocommerce-services-1.22.3.js:107
688
  msgid ""
689
  "You can request a refund for a shipping label that has not been used to ship "
690
  "a package. It will take at least 14 days to process."
691
  msgstr ""
692
 
693
- #: dist/woocommerce-services-1.22.3.js:107
694
  msgid "Purchase date"
695
  msgstr ""
696
 
697
- #: dist/woocommerce-services-1.22.3.js:107
698
  msgid "Amount eligible for refund"
699
  msgstr ""
700
 
701
- #: dist/woocommerce-services-1.22.3.js:107
702
  msgid "Reprint shipping label"
703
  msgstr ""
704
 
705
- #: dist/woocommerce-services-1.22.3.js:107
706
  msgid ""
707
  "If there was a printing error when you purchased the label, you can print it "
708
  "again."
709
  msgstr ""
710
 
711
- #: dist/woocommerce-services-1.22.3.js:107
712
  msgid ""
713
  "NOTE: If you already used the label in a package, printing and using it "
714
  "again is a violation of our terms of service and may result in criminal "
715
  "charges."
716
  msgstr ""
717
 
718
- #: dist/woocommerce-services-1.22.3.js:107
719
  msgid "Label #%(labelIndex)s details"
720
  msgstr ""
721
 
722
- #: dist/woocommerce-services-1.22.3.js:107
723
  msgid "Receipt"
724
  msgstr ""
725
 
726
- #: dist/woocommerce-services-1.22.3.js:107
727
  msgid "Package"
728
  msgstr ""
729
 
730
- #: dist/woocommerce-services-1.22.3.js:107
731
  msgid "Items"
732
  msgstr ""
733
 
734
- #: dist/woocommerce-services-1.22.3.js:107
735
  msgid "N/A"
736
  msgstr ""
737
 
738
- #: dist/woocommerce-services-1.22.3.js:107
739
  msgid "Request refund"
740
  msgstr ""
741
 
742
- #: dist/woocommerce-services-1.22.3.js:107
743
  msgid "Reprint"
744
  msgstr ""
745
 
746
- #: dist/woocommerce-services-1.22.3.js:107
747
  msgid "View details"
748
  msgstr ""
749
 
750
- #: dist/woocommerce-services-1.22.3.js:107
751
  msgid "%(service)s label (#%(labelIndex)d)"
752
  msgstr ""
753
 
754
- #: dist/woocommerce-services-1.22.3.js:107
755
  msgid "Tracking #: {{trackingLink/}}"
756
  msgstr ""
757
 
758
- #: dist/woocommerce-services-1.22.3.js:107
759
  msgid "Internal note"
760
  msgstr ""
761
 
762
- #: dist/woocommerce-services-1.22.3.js:107
763
  msgid "Note sent to customer"
764
  msgstr ""
765
 
766
- #: dist/woocommerce-services-1.22.3.js:107
767
  msgid "%(service)s label (#%(labelNum)d) refund requested (%(amount)s)"
768
  msgstr ""
769
 
770
- #: dist/woocommerce-services-1.22.3.js:107
771
  msgid "%(service)s label (#%(labelNum)d) refunded (%(amount)s)"
772
  msgstr ""
773
 
774
- #: dist/woocommerce-services-1.22.3.js:107
775
  msgid "%(service)s label (#%(labelNum)d) refund rejected"
776
  msgstr ""
777
 
778
- #: dist/woocommerce-services-1.22.3.js:107
779
  msgid "Refund"
780
  msgstr ""
781
 
782
- #: dist/woocommerce-services-1.22.3.js:107
783
  msgid "Refunded %(amount)s"
784
  msgstr ""
785
 
786
- #: dist/woocommerce-services-1.22.3.js:107
787
  msgid "Note"
788
  msgstr ""
789
 
790
- #: dist/woocommerce-services-1.22.3.js:107
791
  msgid "%(count)s event"
792
  msgid_plural "%(count)s events"
793
  msgstr[0] ""
794
  msgstr[1] ""
795
 
796
- #: dist/woocommerce-services-1.22.3.js:107
797
  msgid "Show notes from %(date)s"
798
  msgstr ""
799
 
800
- #: dist/woocommerce-services-1.22.3.js:107
801
  msgid "No activity yet"
802
  msgstr ""
803
 
804
- #: dist/woocommerce-services-1.22.3.js:107
805
  msgid "Which package would you like to track?"
806
  msgstr ""
807
 
808
- #: dist/woocommerce-services-1.22.3.js:107
809
  msgid "Track Packages"
810
  msgstr ""
811
 
812
- #: dist/woocommerce-services-1.22.3.js:107
813
  msgid "Create new label"
814
  msgstr ""
815
 
816
- #: dist/woocommerce-services-1.22.3.js:107
817
  msgid "Connection error: unable to create label at this time"
818
  msgstr ""
819
 
820
- #: dist/woocommerce-services-1.22.3.js:107
821
  msgid "item is ready for shipment"
822
  msgid_plural "items are ready for shipment"
823
  msgstr[0] ""
824
  msgstr[1] ""
825
 
826
- #: dist/woocommerce-services-1.22.3.js:107
827
  msgid "No tracking information available at this time"
828
  msgstr ""
829
 
830
- #: dist/woocommerce-services-1.22.3.js:107
831
  #. Name for WeChat Pay - https://pay.weixin.qq.com/
832
  msgid "WeChat Pay"
833
  msgstr ""
834
 
835
- #: dist/woocommerce-services-1.22.3.js:107
836
  msgid "American Express"
837
  msgstr ""
838
 
839
- #: dist/woocommerce-services-1.22.3.js:107
840
  msgid "Discover"
841
  msgstr ""
842
 
843
- #: dist/woocommerce-services-1.22.3.js:107
844
  msgid "MasterCard"
845
  msgstr ""
846
 
847
- #: dist/woocommerce-services-1.22.3.js:107
848
  msgid "VISA"
849
  msgstr ""
850
 
851
- #: dist/woocommerce-services-1.22.3.js:107
852
  msgid "PayPal"
853
  msgstr ""
854
 
855
- #: dist/woocommerce-services-1.22.3.js:107
856
  msgid "%(card)s ****%(digits)s"
857
  msgstr ""
858
 
859
- #: dist/woocommerce-services-1.22.3.js:107
860
  msgctxt "date is of the form MM/YY"
861
  msgid "Expires %(date)s"
862
  msgstr ""
863
 
864
- #: dist/woocommerce-services-1.22.3.js:107
865
  msgid ""
866
  "Only the site owner can manage shipping label payment methods. Please "
867
  "contact %(ownerName)s (%(ownerLogin)s) to manage payment methods."
868
  msgstr ""
869
 
870
- #: dist/woocommerce-services-1.22.3.js:107
871
  msgid "Retry"
872
  msgstr ""
873
 
874
- #: dist/woocommerce-services-1.22.3.js:107
875
  msgid ""
876
  "Only the site owner can change these settings. Please contact %(ownerName)s "
877
  "(%(ownerLogin)s) to change the shipping label settings."
878
  msgstr ""
879
 
880
- #: dist/woocommerce-services-1.22.3.js:107
881
  msgid ""
882
  "Credit cards are retrieved from the following WordPress.com account: "
883
  "%(wpcomLogin)s <%(wpcomEmail)s>"
884
  msgstr ""
885
 
886
- #: dist/woocommerce-services-1.22.3.js:107
887
  msgid ""
888
  "We'll charge the credit card on your account (%(card)s) to pay for the "
889
  "labels you print"
890
  msgstr ""
891
 
892
- #: dist/woocommerce-services-1.22.3.js:107
893
  msgid "To purchase shipping labels, add a credit card."
894
  msgstr ""
895
 
896
- #: dist/woocommerce-services-1.22.3.js:107
897
  msgid "Choose a different card"
898
  msgstr ""
899
 
900
- #: dist/woocommerce-services-1.22.3.js:107
901
  msgid ""
902
  "To purchase shipping labels, choose a credit card you have on file or add a "
903
  "new card."
904
  msgstr ""
905
 
906
- #: dist/woocommerce-services-1.22.3.js:107
907
  msgid "Add another credit card"
908
  msgstr ""
909
 
910
- #: dist/woocommerce-services-1.22.3.js:107
911
  msgid "Add a credit card"
912
  msgstr ""
913
 
914
- #: dist/woocommerce-services-1.22.3.js:107
915
  msgid "Email Receipts"
916
  msgstr ""
917
 
918
- #: dist/woocommerce-services-1.22.3.js:107
919
  msgid ""
920
  "Email the label purchase receipts to %(ownerName)s (%(ownerLogin)s) at "
921
  "%(ownerEmail)s"
922
  msgstr ""
923
 
924
- #: dist/woocommerce-services-1.22.3.js:107
925
  msgid "Payment"
926
  msgstr ""
927
 
928
- #: dist/woocommerce-services-1.22.3.js:107
929
  msgid "Unable to get your settings. Please refresh the page to try again."
930
  msgstr ""
931
 
932
- #: dist/woocommerce-services-1.22.3.js:107
933
  msgid "Shipping Labels"
934
  msgstr ""
935
 
936
- #: dist/woocommerce-services-1.22.3.js:107
937
  msgid "Print shipping labels yourself and save a trip to the post office."
938
  msgstr ""
939
 
940
- #: dist/woocommerce-services-1.22.3.js:107
941
  msgid "Dimensions"
942
  msgstr ""
943
 
944
- #: dist/woocommerce-services-1.22.3.js:107
945
  msgid "Remove"
946
  msgstr ""
947
 
948
- #: dist/woocommerce-services-1.22.3.js:107
949
  msgid "Add boxes, envelopes, and other packages you use most frequently."
950
  msgstr ""
951
 
952
- #: dist/woocommerce-services-1.22.3.js:107
953
  msgid "Return to Order #%(orderId)s"
954
  msgstr ""
955
 
956
- #: dist/woocommerce-services-1.22.3.js:107
957
  msgid "Your shipping settings have been saved."
958
  msgstr ""
959
 
960
- #: dist/woocommerce-services-1.22.3.js:107
961
  msgid "Unable to save your shipping settings. Please try again."
962
  msgstr ""
963
 
964
- #: dist/woocommerce-services-1.22.3.js:107
965
  msgid "A payment method is required to print shipping labels."
966
  msgstr ""
967
 
968
- #: dist/woocommerce-services-1.22.3.js:107
969
  msgctxt ""
970
  "This section displays the overall health of WooCommerce Services and the "
971
  "things it depends on"
972
  msgid "Health"
973
  msgstr ""
974
 
975
- #: dist/woocommerce-services-1.22.3.js:107
976
  msgid "Last updated %s. {{a}}Refresh{{/a}}"
977
  msgstr ""
978
 
979
- #: dist/woocommerce-services-1.22.3.js:107
980
  msgid "Refresh"
981
  msgstr ""
982
 
983
- #: dist/woocommerce-services-1.22.3.js:107
984
  msgid "WooCommerce"
985
  msgstr ""
986
 
987
- #: dist/woocommerce-services-1.22.3.js:107
988
  msgid "Jetpack"
989
  msgstr ""
990
 
991
- #: dist/woocommerce-services-1.22.3.js:107
992
  msgid "WooCommerce Services Data"
993
  msgstr ""
994
 
995
- #: dist/woocommerce-services-1.22.3.js:107
996
  msgid "Log tail copied to clipboard"
997
  msgstr ""
998
 
999
- #: dist/woocommerce-services-1.22.3.js:107
1000
  msgid "Last %s entry. {{a}}Show full log{{/a}}"
1001
  msgid_plural "Last %s entries. {{a}}Show full log{{/a}}"
1002
  msgstr[0] ""
1003
  msgstr[1] ""
1004
 
1005
- #: dist/woocommerce-services-1.22.3.js:107
1006
  msgid "Copy for support"
1007
  msgstr ""
1008
 
1009
- #: dist/woocommerce-services-1.22.3.js:107
1010
  msgid ""
1011
  "Request was made %s - check logs below or {{a}}edit service settings{{/a}}"
1012
  msgstr ""
1013
 
1014
- #: dist/woocommerce-services-1.22.3.js:107
1015
  msgid "Edit service settings"
1016
  msgstr ""
1017
 
1018
- #: dist/woocommerce-services-1.22.3.js:107
1019
  msgid "Services"
1020
  msgstr ""
1021
 
1022
- #: dist/woocommerce-services-1.22.3.js:107
1023
  msgid "No services configured. {{a}}Add a shipping service{{/a}}"
1024
  msgstr ""
1025
 
1026
- #: dist/woocommerce-services-1.22.3.js:107
1027
  msgid "Debug"
1028
  msgstr ""
1029
 
1030
- #: dist/woocommerce-services-1.22.3.js:107
1031
  msgid "Display troubleshooting information on the Cart and Checkout pages."
1032
  msgstr ""
1033
 
1034
- #: dist/woocommerce-services-1.22.3.js:107
1035
  msgid "Enabled"
1036
  msgstr ""
1037
 
1038
- #: dist/woocommerce-services-1.22.3.js:107
1039
  msgid "Disabled"
1040
  msgstr ""
1041
 
1042
- #: dist/woocommerce-services-1.22.3.js:107
1043
  msgid "Logging"
1044
  msgstr ""
1045
 
1046
- #: dist/woocommerce-services-1.22.3.js:107
1047
  msgid ""
1048
  "Write diagnostic messages to log files. Helpful when contacting support."
1049
  msgstr ""
1050
 
1051
- #: dist/woocommerce-services-1.22.3.js:107
1052
  msgid "Shipping Log"
1053
  msgstr ""
1054
 
1055
- #: dist/woocommerce-services-1.22.3.js:107
1056
  msgid "Taxes Log"
1057
  msgstr ""
1058
 
1059
- #: dist/woocommerce-services-1.22.3.js:107
1060
  msgid "Other Log"
1061
  msgstr ""
1062
 
1063
- #: dist/woocommerce-services-1.22.3.js:107
1064
  msgid "Support"
1065
  msgstr ""
1066
 
1067
- #: dist/woocommerce-services-1.22.3.js:107
1068
  msgid "Need help?"
1069
  msgstr ""
1070
 
1071
- #: dist/woocommerce-services-1.22.3.js:107
1072
  msgid ""
1073
  "Our team is here for you. View our {{docsA}}support docs{{/docsA}} or "
1074
  "{{ticketA}}open a support ticket{{/ticketA}}."
1075
  msgstr ""
1076
 
1077
- #: dist/woocommerce-services-1.22.3.js:107
1078
  msgid "Activated"
1079
  msgstr ""
1080
 
1081
- #: dist/woocommerce-services-1.22.3.js:107
1082
  msgid "Check email to activate account"
1083
  msgstr ""
1084
 
1085
- #: dist/woocommerce-services-1.22.3.js:107
1086
  msgid "Disconnecting"
1087
  msgstr ""
1088
 
1089
- #: dist/woocommerce-services-1.22.3.js:107
1090
  msgid "Disconnect"
1091
  msgstr ""
1092
 
1093
- #: dist/woocommerce-services-1.22.3.js:107
1094
  msgid "Stripe account"
1095
  msgstr ""
1096
 
1097
- #: dist/woocommerce-services-1.22.3.js:107
1098
  msgid "Account disconnected. Reloading page…"
1099
  msgstr ""
1100
 
1101
- #: dist/woocommerce-services-1.22.3.js:107
1102
  msgid ""
1103
  "You’ve got WooCommerce Services installed. If you’d like, we can "
1104
  "automatically copy keys from your Stripe account for you. {{a}}Click here{{/"
4
  msgstr ""
5
  "Project-Id-Version: _s woocommerce-services\n"
6
  "Report-Msgid-Bugs-To: \n"
7
+ "POT-Creation-Date: 2020-03-02T19:26:19.771Z\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
12
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13
  "Language-Team: LANGUAGE <LL@li.org>\n"
14
 
15
+ #: dist/woocommerce-services-1.22.4.js:107
16
  msgid "Dismiss"
17
  msgstr ""
18
 
19
+ #: dist/woocommerce-services-1.22.4.js:107
20
  msgid "Required"
21
  msgstr ""
22
 
23
+ #: dist/woocommerce-services-1.22.4.js:107
24
  msgid "Optional"
25
  msgstr ""
26
 
27
+ #: dist/woocommerce-services-1.22.4.js:107
28
  msgid "More"
29
  msgstr ""
30
 
31
+ #: dist/woocommerce-services-1.22.4.js:107
32
  msgid "All services selected"
33
  msgstr ""
34
 
35
+ #: dist/woocommerce-services-1.22.4.js:107
36
  msgid "%(numSelected)d service selected"
37
  msgid_plural "%(numSelected)d services selected"
38
  msgstr[0] ""
39
  msgstr[1] ""
40
 
41
+ #: dist/woocommerce-services-1.22.4.js:107
42
  msgid "Expand Services"
43
  msgstr ""
44
 
45
+ #: dist/woocommerce-services-1.22.4.js:107
46
  msgid "Service"
47
  msgstr ""
48
 
49
+ #: dist/woocommerce-services-1.22.4.js:107
50
  msgid "Price adjustment"
51
  msgstr ""
52
 
53
+ #: dist/woocommerce-services-1.22.4.js:107
54
  msgid ""
55
  "Increase the rates calculated by the carrier to account for packaging and "
56
  "handling costs. You can also add a negative amount to save your customers "
57
  "money."
58
  msgstr ""
59
 
60
+ #: dist/woocommerce-services-1.22.4.js:107
61
  msgid "Saved Packages"
62
  msgstr ""
63
 
64
+ #: dist/woocommerce-services-1.22.4.js:107
65
  msgid "Add and edit saved packages using the {{a}}Packaging Manager{{/a}}."
66
  msgstr ""
67
 
68
+ #: dist/woocommerce-services-1.22.4.js:107
69
  msgid "You have unsaved changes."
70
  msgstr ""
71
 
72
+ #: dist/woocommerce-services-1.22.4.js:107
73
  msgid "Your changes have been saved."
74
  msgstr ""
75
 
76
+ #: dist/woocommerce-services-1.22.4.js:107
77
  msgid ""
78
  "There was a problem with one or more entries. Please fix the errors below "
79
  "and try saving again."
80
  msgstr ""
81
 
82
+ #: dist/woocommerce-services-1.22.4.js:107
83
  msgid "Save changes"
84
  msgstr ""
85
 
86
+ #: dist/woocommerce-services-1.22.4.js:107
87
  msgid "Saving…"
88
  msgstr ""
89
 
90
+ #: dist/woocommerce-services-1.22.4.js:107
91
  msgid "Save Settings"
92
  msgstr ""
93
 
94
+ #: dist/woocommerce-services-1.22.4.js:107
95
  msgid ""
96
  "We have slightly modified the address entered. If correct, please use the "
97
  "suggested address to ensure accurate delivery."
98
  msgstr ""
99
 
100
+ #: dist/woocommerce-services-1.22.4.js:107
101
  msgid "Address entered"
102
  msgstr ""
103
 
104
+ #: dist/woocommerce-services-1.22.4.js:107
105
  msgid "Suggested address"
106
  msgstr ""
107
 
108
+ #: dist/woocommerce-services-1.22.4.js:107
109
  msgid "Use selected address"
110
  msgstr ""
111
 
112
+ #: dist/woocommerce-services-1.22.4.js:107
113
  msgid "Edit address"
114
  msgstr ""
115
 
116
+ #: dist/woocommerce-services-1.22.4.js:107
117
  msgid "We were unable to automatically verify the address — %(error)s."
118
  msgstr ""
119
 
120
+ #: dist/woocommerce-services-1.22.4.js:107
121
  msgid "We were unable to automatically verify the address."
122
  msgstr ""
123
 
124
+ #: dist/woocommerce-services-1.22.4.js:107
125
  msgid ""
126
  "Automatic verification failed for this address. It may still be a valid "
127
  "address — use the tools below to manually verify."
128
  msgstr ""
129
 
130
+ #: dist/woocommerce-services-1.22.4.js:107
131
  msgid "Verify with USPS"
132
  msgstr ""
133
 
134
+ #: dist/woocommerce-services-1.22.4.js:107
135
  msgid "View on Google Maps"
136
  msgstr ""
137
 
138
+ #: dist/woocommerce-services-1.22.4.js:107
139
  msgid "Use address as entered"
140
  msgstr ""
141
 
142
+ #: dist/woocommerce-services-1.22.4.js:107
143
  msgid "Name"
144
  msgstr ""
145
 
146
+ #: dist/woocommerce-services-1.22.4.js:107
147
  msgid "Company"
148
  msgstr ""
149
 
150
+ #: dist/woocommerce-services-1.22.4.js:107
151
  msgid "Phone"
152
  msgstr ""
153
 
154
+ #: dist/woocommerce-services-1.22.4.js:107
155
  msgid "%(message)s. Please modify the address and try again."
156
  msgstr ""
157
 
158
+ #: dist/woocommerce-services-1.22.4.js:107
159
  msgid "Address"
160
  msgstr ""
161
 
162
+ #: dist/woocommerce-services-1.22.4.js:107
163
  msgid "City"
164
  msgstr ""
165
 
166
+ #: dist/woocommerce-services-1.22.4.js:107
167
  msgid "State"
168
  msgstr ""
169
 
170
+ #: dist/woocommerce-services-1.22.4.js:107
171
  msgid "Select one…"
172
  msgstr ""
173
 
174
+ #: dist/woocommerce-services-1.22.4.js:107
175
  msgid "Postal code"
176
  msgstr ""
177
 
178
+ #: dist/woocommerce-services-1.22.4.js:107
179
  msgid "Country"
180
  msgstr ""
181
 
182
+ #: dist/woocommerce-services-1.22.4.js:107
183
  msgid "Verify address"
184
  msgstr ""
185
 
186
+ #: dist/woocommerce-services-1.22.4.js:107
187
  msgid "Expand"
188
  msgstr ""
189
 
190
+ #: dist/woocommerce-services-1.22.4.js:107
191
  msgid "Validating address…"
192
  msgstr ""
193
 
194
+ #: dist/woocommerce-services-1.22.4.js:107
195
  msgid "Invalid address"
196
  msgstr ""
197
 
198
+ #: dist/woocommerce-services-1.22.4.js:107
199
  msgid "You've edited the address, please revalidate it for accurate rates"
200
  msgstr ""
201
 
202
+ #: dist/woocommerce-services-1.22.4.js:107
203
  msgid "Packages to be Shipped"
204
  msgstr ""
205
 
206
+ #: dist/woocommerce-services-1.22.4.js:107
207
  msgid "Move"
208
  msgstr ""
209
 
210
+ #: dist/woocommerce-services-1.22.4.js:107
211
  #. Length placeholder for dimensions input
212
  msgid "L"
213
  msgstr ""
214
 
215
+ #: dist/woocommerce-services-1.22.4.js:107
216
  #. Width placeholder for dimensions input
217
  msgid "W"
218
  msgstr ""
219
 
220
+ #: dist/woocommerce-services-1.22.4.js:107
221
  #. Height placeholder for dimensions input
222
  msgid "H"
223
  msgstr ""
224
 
225
+ #: dist/woocommerce-services-1.22.4.js:107
226
  msgid "Invalid value."
227
  msgstr ""
228
 
229
+ #: dist/woocommerce-services-1.22.4.js:107
230
  msgid "This field is required."
231
  msgstr ""
232
 
233
+ #: dist/woocommerce-services-1.22.4.js:107
234
  msgid "Type of package"
235
  msgstr ""
236
 
237
+ #: dist/woocommerce-services-1.22.4.js:107
238
  msgid "Box"
239
  msgstr ""
240
 
241
+ #: dist/woocommerce-services-1.22.4.js:107
242
  msgid "Envelope"
243
  msgstr ""
244
 
245
+ #: dist/woocommerce-services-1.22.4.js:107
246
  msgid "Package name"
247
  msgstr ""
248
 
249
+ #: dist/woocommerce-services-1.22.4.js:107
250
  msgid "Unique package name"
251
  msgstr ""
252
 
253
+ #: dist/woocommerce-services-1.22.4.js:107
254
  msgid "This field must be unique"
255
  msgstr ""
256
 
257
+ #: dist/woocommerce-services-1.22.4.js:107
258
  msgid "Dimensions (L x W x H)"
259
  msgstr ""
260
 
261
+ #: dist/woocommerce-services-1.22.4.js:107
262
  msgid "Weight of empty package"
263
  msgstr ""
264
 
265
+ #: dist/woocommerce-services-1.22.4.js:107
266
  msgid "0.0"
267
  msgstr ""
268
 
269
+ #: dist/woocommerce-services-1.22.4.js:107
270
  msgid "Untitled"
271
  msgstr ""
272
 
273
+ #: dist/woocommerce-services-1.22.4.js:107
274
  msgid "All packages selected"
275
  msgstr ""
276
 
277
+ #: dist/woocommerce-services-1.22.4.js:107
278
  msgid "%(selectedCount)d package selected"
279
  msgid_plural "%(selectedCount)d packages selected"
280
  msgstr[0] ""
281
  msgstr[1] ""
282
 
283
+ #: dist/woocommerce-services-1.22.4.js:107
284
  msgid "Your shipping packages have been saved."
285
  msgstr ""
286
 
287
+ #: dist/woocommerce-services-1.22.4.js:107
288
  msgid "Unable to save your shipping packages. Please try again."
289
  msgstr ""
290
 
291
+ #: dist/woocommerce-services-1.22.4.js:107
292
  msgid "Add package"
293
  msgid_plural "Add packages"
294
  msgstr[0] ""
295
  msgstr[1] ""
296
 
297
+ #: dist/woocommerce-services-1.22.4.js:107
298
  msgid "Done"
299
  msgstr ""
300
 
301
+ #: dist/woocommerce-services-1.22.4.js:107
302
  msgid "Cancel"
303
  msgstr ""
304
 
305
+ #: dist/woocommerce-services-1.22.4.js:107
306
  msgid "{{icon/}} Delete this package"
307
  msgstr ""
308
 
309
+ #: dist/woocommerce-services-1.22.4.js:107
310
  msgid "Individually Shipped Item"
311
  msgstr ""
312
 
313
+ #: dist/woocommerce-services-1.22.4.js:107
314
  msgid "Item Dimensions"
315
  msgstr ""
316
 
317
+ #: dist/woocommerce-services-1.22.4.js:107
318
  msgid "Package details"
319
  msgstr ""
320
 
321
+ #: dist/woocommerce-services-1.22.4.js:107
322
  msgid "Select a package type"
323
  msgstr ""
324
 
325
+ #: dist/woocommerce-services-1.22.4.js:107
326
  msgid "Please select a package"
327
  msgstr ""
328
 
329
+ #: dist/woocommerce-services-1.22.4.js:107
330
  msgid "Add items"
331
  msgstr ""
332
 
333
+ #: dist/woocommerce-services-1.22.4.js:107
334
  msgid "Items to fulfill"
335
  msgstr ""
336
 
337
+ #: dist/woocommerce-services-1.22.4.js:107
338
  msgid "Weight"
339
  msgstr ""
340
 
341
+ #: dist/woocommerce-services-1.22.4.js:107
342
  msgid "QTY"
343
  msgstr ""
344
 
345
+ #: dist/woocommerce-services-1.22.4.js:107
346
  msgid "There are no items in this package."
347
  msgstr ""
348
 
349
+ #: dist/woocommerce-services-1.22.4.js:107
350
  msgid "Total Weight (with package)"
351
  msgstr ""
352
 
353
+ #: dist/woocommerce-services-1.22.4.js:107
354
  msgid "0"
355
  msgstr ""
356
 
357
+ #: dist/woocommerce-services-1.22.4.js:107
358
  msgid "{{itemLink/}} is currently saved for a later shipment."
359
  msgstr ""
360
 
361
+ #: dist/woocommerce-services-1.22.4.js:107
362
  msgid "{{itemLink/}} is currently shipped in its original packaging."
363
  msgstr ""
364
 
365
+ #: dist/woocommerce-services-1.22.4.js:107
366
  msgid "{{itemLink/}} is currently in {{pckg/}}."
367
  msgstr ""
368
 
369
+ #: dist/woocommerce-services-1.22.4.js:107
370
  msgid "Submit"
371
  msgstr ""
372
 
373
+ #: dist/woocommerce-services-1.22.4.js:107
374
  msgid "Move item"
375
  msgstr ""
376
 
377
+ #: dist/woocommerce-services-1.22.4.js:107
378
  msgid "Where would you like to move it?"
379
  msgstr ""
380
 
381
+ #: dist/woocommerce-services-1.22.4.js:107
382
  msgid "Add to a New Package"
383
  msgstr ""
384
 
385
+ #: dist/woocommerce-services-1.22.4.js:107
386
  msgid "Ship in original packaging"
387
  msgstr ""
388
 
389
+ #: dist/woocommerce-services-1.22.4.js:107
390
  msgid "Remove from package"
391
  msgstr ""
392
 
393
+ #: dist/woocommerce-services-1.22.4.js:107
394
  msgid "%(item)s from {{pckg/}}"
395
  msgstr ""
396
 
397
+ #: dist/woocommerce-services-1.22.4.js:107
398
  msgid "Close"
399
  msgstr ""
400
 
401
+ #: dist/woocommerce-services-1.22.4.js:107
402
  msgid "Add"
403
  msgstr ""
404
 
405
+ #: dist/woocommerce-services-1.22.4.js:107
406
  msgid "Add item"
407
  msgstr ""
408
 
409
+ #: dist/woocommerce-services-1.22.4.js:107
410
  msgid "Which items would you like to add to {{pckg/}}?"
411
  msgstr ""
412
 
413
+ #: dist/woocommerce-services-1.22.4.js:107
414
  msgid "Packaging"
415
  msgstr ""
416
 
417
+ #: dist/woocommerce-services-1.22.4.js:107
418
  msgid "No packages selected"
419
  msgstr ""
420
 
421
+ #: dist/woocommerce-services-1.22.4.js:107
422
  msgid "1 item in 1 package: %(weight)s %(unit)s total"
423
  msgstr ""
424
 
425
+ #: dist/woocommerce-services-1.22.4.js:107
426
  msgid "%(itemsCount)d items in 1 package: %(weight)s %(unit)s total"
427
  msgstr ""
428
 
429
+ #: dist/woocommerce-services-1.22.4.js:107
430
  msgid ""
431
  "%(itemsCount)d items in %(packageCount)d packages: %(weight)s %(unit)s total"
432
  msgstr ""
433
 
434
+ #: dist/woocommerce-services-1.22.4.js:107
435
  msgid "Use these packages"
436
  msgstr ""
437
 
438
+ #: dist/woocommerce-services-1.22.4.js:107
439
  msgid "HS Tariff number"
440
  msgstr ""
441
 
442
+ #: dist/woocommerce-services-1.22.4.js:107
443
  msgid "more info"
444
  msgstr ""
445
 
446
+ #: dist/woocommerce-services-1.22.4.js:107
447
  msgid "Origin country"
448
  msgstr ""
449
 
450
+ #: dist/woocommerce-services-1.22.4.js:107
451
  msgid "Country where the product was manufactured or assembled"
452
  msgstr ""
453
 
454
+ #: dist/woocommerce-services-1.22.4.js:107
455
  msgid "Description"
456
  msgstr ""
457
 
458
+ #: dist/woocommerce-services-1.22.4.js:107
459
  msgid "Weight (%s per unit)"
460
  msgstr ""
461
 
462
+ #: dist/woocommerce-services-1.22.4.js:107
463
  msgid "Value ($ per unit)"
464
  msgstr ""
465
 
466
+ #: dist/woocommerce-services-1.22.4.js:107
467
  msgid "Weight (per unit)"
468
  msgstr ""
469
 
470
+ #: dist/woocommerce-services-1.22.4.js:107
471
  msgid "Value (per unit)"
472
  msgstr ""
473
 
474
+ #: dist/woocommerce-services-1.22.4.js:107
475
  msgid "Return to sender if package is unable to be delivered"
476
  msgstr ""
477
 
478
+ #: dist/woocommerce-services-1.22.4.js:107
479
  msgid "Contents type"
480
  msgstr ""
481
 
482
+ #: dist/woocommerce-services-1.22.4.js:107
483
  msgid "Merchandise"
484
  msgstr ""
485
 
486
+ #: dist/woocommerce-services-1.22.4.js:107
487
  msgid "Documents"
488
  msgstr ""
489
 
490
+ #: dist/woocommerce-services-1.22.4.js:107
491
  msgid "Gift"
492
  msgstr ""
493
 
494
+ #: dist/woocommerce-services-1.22.4.js:107
495
  msgid "Sample"
496
  msgstr ""
497
 
498
+ #: dist/woocommerce-services-1.22.4.js:107
499
  msgid "Other…"
500
  msgstr ""
501
 
502
+ #: dist/woocommerce-services-1.22.4.js:107
503
  msgid "Details"
504
  msgstr ""
505
 
506
+ #: dist/woocommerce-services-1.22.4.js:107
507
  msgid "Restriction type"
508
  msgstr ""
509
 
510
+ #: dist/woocommerce-services-1.22.4.js:107
511
  msgid "None"
512
  msgstr ""
513
 
514
+ #: dist/woocommerce-services-1.22.4.js:107
515
  msgid "Quarantine"
516
  msgstr ""
517
 
518
+ #: dist/woocommerce-services-1.22.4.js:107
519
  msgid "Sanitary / Phytosanitary inspection"
520
  msgstr ""
521
 
522
+ #: dist/woocommerce-services-1.22.4.js:107
523
  msgid "ITN"
524
  msgstr ""
525
 
526
+ #: dist/woocommerce-services-1.22.4.js:107
527
  msgid "Customs information incomplete"
528
  msgstr ""
529
 
530
+ #: dist/woocommerce-services-1.22.4.js:107
531
  msgid "Customs information valid"
532
  msgstr ""
533
 
534
+ #: dist/woocommerce-services-1.22.4.js:107
535
  msgid "Customs"
536
  msgstr ""
537
 
538
+ #: dist/woocommerce-services-1.22.4.js:107
539
  msgid "Save customs form"
540
  msgstr ""
541
 
542
+ #: dist/woocommerce-services-1.22.4.js:107
543
  msgid ""
544
  "The service and rate chosen by the customer at checkout is not available. "
545
  "Please choose another."
546
  msgstr ""
547
 
548
+ #: dist/woocommerce-services-1.22.4.js:107
549
  msgid "Choose rate: %(pckg)s"
550
  msgstr ""
551
 
552
+ #: dist/woocommerce-services-1.22.4.js:107
553
  msgid "Unsaved changes made to packages"
554
  msgstr ""
555
 
556
+ #: dist/woocommerce-services-1.22.4.js:107
557
  msgid "No rates found"
558
  msgstr ""
559
 
560
+ #: dist/woocommerce-services-1.22.4.js:107
561
  msgid "%(serviceName)s: %(rate)s"
562
  msgstr ""
563
 
564
+ #: dist/woocommerce-services-1.22.4.js:107
565
  msgid "Total rate: %(total)s"
566
  msgstr ""
567
 
568
+ #: dist/woocommerce-services-1.22.4.js:107
569
  msgid "Shipping rates"
570
  msgstr ""
571
 
572
+ #: dist/woocommerce-services-1.22.4.js:107
573
  msgid "Customer paid a {{shippingMethod/}} of {{shippingCost/}} for shipping"
574
  msgstr ""
575
 
576
+ #: dist/woocommerce-services-1.22.4.js:107
577
  msgid "Your customer selected {{shippingMethod/}}"
578
  msgstr ""
579
 
580
+ #: dist/woocommerce-services-1.22.4.js:107
581
  msgid ""
582
  "WooCommerce Services gives you access to USPS Commercial Pricing, which is "
583
  "discounted over Retail rates."
584
  msgstr ""
585
 
586
+ #: dist/woocommerce-services-1.22.4.js:107
587
  msgid "Package %(index)s"
588
  msgstr ""
589
 
590
+ #: dist/woocommerce-services-1.22.4.js:107
591
  msgid "You save"
592
  msgstr ""
593
 
594
+ #: dist/woocommerce-services-1.22.4.js:107
595
  msgid "Total"
596
  msgstr ""
597
 
598
+ #: dist/woocommerce-services-1.22.4.js:107
599
  msgid "Shipping summary"
600
  msgstr ""
601
 
602
+ #: dist/woocommerce-services-1.22.4.js:107
603
  msgid "Shipping from"
604
  msgstr ""
605
 
606
+ #: dist/woocommerce-services-1.22.4.js:107
607
  msgid "Edit"
608
  msgstr ""
609
 
610
+ #: dist/woocommerce-services-1.22.4.js:107
611
  msgid "shipping label ready"
612
  msgid_plural "shipping labels ready"
613
  msgstr[0] ""
614
  msgstr[1] ""
615
 
616
+ #: dist/woocommerce-services-1.22.4.js:107
617
  msgid "Print"
618
  msgstr ""
619
 
620
+ #: dist/woocommerce-services-1.22.4.js:107
621
  msgid "Purchasing…"
622
  msgstr ""
623
 
624
+ #: dist/woocommerce-services-1.22.4.js:107
625
  msgid "Buy shipping labels"
626
  msgstr ""
627
 
628
+ #: dist/woocommerce-services-1.22.4.js:107
629
  msgid "Choose credit card"
630
  msgstr ""
631
 
632
+ #: dist/woocommerce-services-1.22.4.js:107
633
  msgid ""
634
  "To print this shipping label, {{a}}choose a credit card to your account{{/"
635
  "a}}."
636
  msgstr ""
637
 
638
+ #: dist/woocommerce-services-1.22.4.js:107
639
  msgid "Add credit card"
640
  msgstr ""
641
 
642
+ #: dist/woocommerce-services-1.22.4.js:107
643
  msgid ""
644
  "To print this shipping label, {{a}}add a credit card to your account{{/a}}."
645
  msgstr ""
646
 
647
+ #: dist/woocommerce-services-1.22.4.js:107
648
  msgid "Email shipment details to the customer"
649
  msgstr ""
650
 
651
+ #: dist/woocommerce-services-1.22.4.js:107
652
  msgid "Mark the order as fulfilled"
653
  msgstr ""
654
 
655
+ #: dist/woocommerce-services-1.22.4.js:107
656
  msgid "Paper size"
657
  msgstr ""
658
 
659
+ #: dist/woocommerce-services-1.22.4.js:107
660
  msgid "Create shipping label"
661
  msgstr ""
662
 
663
+ #: dist/woocommerce-services-1.22.4.js:107
664
  msgid "Create shipping labels"
665
  msgstr ""
666
 
667
+ #: dist/woocommerce-services-1.22.4.js:107
668
  msgid "Origin address"
669
  msgstr ""
670
 
671
+ #: dist/woocommerce-services-1.22.4.js:107
672
  msgid "Destination address"
673
  msgstr ""
674
 
675
+ #: dist/woocommerce-services-1.22.4.js:107
676
  msgid "Toggle menu"
677
  msgstr ""
678
 
679
+ #: dist/woocommerce-services-1.22.4.js:107
680
  msgid "Refund label (-%(amount)s)"
681
  msgstr ""
682
 
683
+ #: dist/woocommerce-services-1.22.4.js:107
684
  msgid "Request a refund"
685
  msgstr ""
686
 
687
+ #: dist/woocommerce-services-1.22.4.js:107
688
  msgid ""
689
  "You can request a refund for a shipping label that has not been used to ship "
690
  "a package. It will take at least 14 days to process."
691
  msgstr ""
692
 
693
+ #: dist/woocommerce-services-1.22.4.js:107
694
  msgid "Purchase date"
695
  msgstr ""
696
 
697
+ #: dist/woocommerce-services-1.22.4.js:107
698
  msgid "Amount eligible for refund"
699
  msgstr ""
700
 
701
+ #: dist/woocommerce-services-1.22.4.js:107
702
  msgid "Reprint shipping label"
703
  msgstr ""
704
 
705
+ #: dist/woocommerce-services-1.22.4.js:107
706
  msgid ""
707
  "If there was a printing error when you purchased the label, you can print it "
708
  "again."
709
  msgstr ""
710
 
711
+ #: dist/woocommerce-services-1.22.4.js:107
712
  msgid ""
713
  "NOTE: If you already used the label in a package, printing and using it "
714
  "again is a violation of our terms of service and may result in criminal "
715
  "charges."
716
  msgstr ""
717
 
718
+ #: dist/woocommerce-services-1.22.4.js:107
719
  msgid "Label #%(labelIndex)s details"
720
  msgstr ""
721
 
722
+ #: dist/woocommerce-services-1.22.4.js:107
723
  msgid "Receipt"
724
  msgstr ""
725
 
726
+ #: dist/woocommerce-services-1.22.4.js:107
727
  msgid "Package"
728
  msgstr ""
729
 
730
+ #: dist/woocommerce-services-1.22.4.js:107
731
  msgid "Items"
732
  msgstr ""
733
 
734
+ #: dist/woocommerce-services-1.22.4.js:107
735
  msgid "N/A"
736
  msgstr ""
737
 
738
+ #: dist/woocommerce-services-1.22.4.js:107
739
  msgid "Request refund"
740
  msgstr ""
741
 
742
+ #: dist/woocommerce-services-1.22.4.js:107
743
  msgid "Reprint"
744
  msgstr ""
745
 
746
+ #: dist/woocommerce-services-1.22.4.js:107
747
  msgid "View details"
748
  msgstr ""
749
 
750
+ #: dist/woocommerce-services-1.22.4.js:107
751
  msgid "%(service)s label (#%(labelIndex)d)"
752
  msgstr ""
753
 
754
+ #: dist/woocommerce-services-1.22.4.js:107
755
  msgid "Tracking #: {{trackingLink/}}"
756
  msgstr ""
757
 
758
+ #: dist/woocommerce-services-1.22.4.js:107
759
  msgid "Internal note"
760
  msgstr ""
761
 
762
+ #: dist/woocommerce-services-1.22.4.js:107
763
  msgid "Note sent to customer"
764
  msgstr ""
765
 
766
+ #: dist/woocommerce-services-1.22.4.js:107
767
  msgid "%(service)s label (#%(labelNum)d) refund requested (%(amount)s)"
768
  msgstr ""
769
 
770
+ #: dist/woocommerce-services-1.22.4.js:107
771
  msgid "%(service)s label (#%(labelNum)d) refunded (%(amount)s)"
772
  msgstr ""
773
 
774
+ #: dist/woocommerce-services-1.22.4.js:107
775
  msgid "%(service)s label (#%(labelNum)d) refund rejected"
776
  msgstr ""
777
 
778
+ #: dist/woocommerce-services-1.22.4.js:107
779
  msgid "Refund"
780
  msgstr ""
781
 
782
+ #: dist/woocommerce-services-1.22.4.js:107
783
  msgid "Refunded %(amount)s"
784
  msgstr ""
785
 
786
+ #: dist/woocommerce-services-1.22.4.js:107
787
  msgid "Note"
788
  msgstr ""
789
 
790
+ #: dist/woocommerce-services-1.22.4.js:107
791
  msgid "%(count)s event"
792
  msgid_plural "%(count)s events"
793
  msgstr[0] ""
794
  msgstr[1] ""
795
 
796
+ #: dist/woocommerce-services-1.22.4.js:107
797
  msgid "Show notes from %(date)s"
798
  msgstr ""
799
 
800
+ #: dist/woocommerce-services-1.22.4.js:107
801
  msgid "No activity yet"
802
  msgstr ""
803
 
804
+ #: dist/woocommerce-services-1.22.4.js:107
805
  msgid "Which package would you like to track?"
806
  msgstr ""
807
 
808
+ #: dist/woocommerce-services-1.22.4.js:107
809
  msgid "Track Packages"
810
  msgstr ""
811
 
812
+ #: dist/woocommerce-services-1.22.4.js:107
813
  msgid "Create new label"
814
  msgstr ""
815
 
816
+ #: dist/woocommerce-services-1.22.4.js:107
817
  msgid "Connection error: unable to create label at this time"
818
  msgstr ""
819
 
820
+ #: dist/woocommerce-services-1.22.4.js:107
821
  msgid "item is ready for shipment"
822
  msgid_plural "items are ready for shipment"
823
  msgstr[0] ""
824
  msgstr[1] ""
825
 
826
+ #: dist/woocommerce-services-1.22.4.js:107
827
  msgid "No tracking information available at this time"
828
  msgstr ""
829
 
830
+ #: dist/woocommerce-services-1.22.4.js:107
831
  #. Name for WeChat Pay - https://pay.weixin.qq.com/
832
  msgid "WeChat Pay"
833
  msgstr ""
834
 
835
+ #: dist/woocommerce-services-1.22.4.js:107
836
  msgid "American Express"
837
  msgstr ""
838
 
839
+ #: dist/woocommerce-services-1.22.4.js:107
840
  msgid "Discover"
841
  msgstr ""
842
 
843
+ #: dist/woocommerce-services-1.22.4.js:107
844
  msgid "MasterCard"
845
  msgstr ""
846
 
847
+ #: dist/woocommerce-services-1.22.4.js:107
848
  msgid "VISA"
849
  msgstr ""
850
 
851
+ #: dist/woocommerce-services-1.22.4.js:107
852
  msgid "PayPal"
853
  msgstr ""
854
 
855
+ #: dist/woocommerce-services-1.22.4.js:107
856
  msgid "%(card)s ****%(digits)s"
857
  msgstr ""
858
 
859
+ #: dist/woocommerce-services-1.22.4.js:107
860
  msgctxt "date is of the form MM/YY"
861
  msgid "Expires %(date)s"
862
  msgstr ""
863
 
864
+ #: dist/woocommerce-services-1.22.4.js:107
865
  msgid ""
866
  "Only the site owner can manage shipping label payment methods. Please "
867
  "contact %(ownerName)s (%(ownerLogin)s) to manage payment methods."
868
  msgstr ""
869
 
870
+ #: dist/woocommerce-services-1.22.4.js:107
871
  msgid "Retry"
872
  msgstr ""
873
 
874
+ #: dist/woocommerce-services-1.22.4.js:107
875
  msgid ""
876
  "Only the site owner can change these settings. Please contact %(ownerName)s "
877
  "(%(ownerLogin)s) to change the shipping label settings."
878
  msgstr ""
879
 
880
+ #: dist/woocommerce-services-1.22.4.js:107
881
  msgid ""
882
  "Credit cards are retrieved from the following WordPress.com account: "
883
  "%(wpcomLogin)s <%(wpcomEmail)s>"
884
  msgstr ""
885
 
886
+ #: dist/woocommerce-services-1.22.4.js:107
887
  msgid ""
888
  "We'll charge the credit card on your account (%(card)s) to pay for the "
889
  "labels you print"
890
  msgstr ""
891
 
892
+ #: dist/woocommerce-services-1.22.4.js:107
893
  msgid "To purchase shipping labels, add a credit card."
894
  msgstr ""
895
 
896
+ #: dist/woocommerce-services-1.22.4.js:107
897
  msgid "Choose a different card"
898
  msgstr ""
899
 
900
+ #: dist/woocommerce-services-1.22.4.js:107
901
  msgid ""
902
  "To purchase shipping labels, choose a credit card you have on file or add a "
903
  "new card."
904
  msgstr ""
905
 
906
+ #: dist/woocommerce-services-1.22.4.js:107
907
  msgid "Add another credit card"
908
  msgstr ""
909
 
910
+ #: dist/woocommerce-services-1.22.4.js:107
911
  msgid "Add a credit card"
912
  msgstr ""
913
 
914
+ #: dist/woocommerce-services-1.22.4.js:107
915
  msgid "Email Receipts"
916
  msgstr ""
917
 
918
+ #: dist/woocommerce-services-1.22.4.js:107
919
  msgid ""
920
  "Email the label purchase receipts to %(ownerName)s (%(ownerLogin)s) at "
921
  "%(ownerEmail)s"
922
  msgstr ""
923
 
924
+ #: dist/woocommerce-services-1.22.4.js:107
925
  msgid "Payment"
926
  msgstr ""
927
 
928
+ #: dist/woocommerce-services-1.22.4.js:107
929
  msgid "Unable to get your settings. Please refresh the page to try again."
930
  msgstr ""
931
 
932
+ #: dist/woocommerce-services-1.22.4.js:107
933
  msgid "Shipping Labels"
934
  msgstr ""
935
 
936
+ #: dist/woocommerce-services-1.22.4.js:107
937
  msgid "Print shipping labels yourself and save a trip to the post office."
938
  msgstr ""
939
 
940
+ #: dist/woocommerce-services-1.22.4.js:107
941
  msgid "Dimensions"
942
  msgstr ""
943
 
944
+ #: dist/woocommerce-services-1.22.4.js:107
945
  msgid "Remove"
946
  msgstr ""
947
 
948
+ #: dist/woocommerce-services-1.22.4.js:107
949
  msgid "Add boxes, envelopes, and other packages you use most frequently."
950
  msgstr ""
951
 
952
+ #: dist/woocommerce-services-1.22.4.js:107
953
  msgid "Return to Order #%(orderId)s"
954
  msgstr ""
955
 
956
+ #: dist/woocommerce-services-1.22.4.js:107
957
  msgid "Your shipping settings have been saved."
958
  msgstr ""
959
 
960
+ #: dist/woocommerce-services-1.22.4.js:107
961
  msgid "Unable to save your shipping settings. Please try again."
962
  msgstr ""
963
 
964
+ #: dist/woocommerce-services-1.22.4.js:107
965
  msgid "A payment method is required to print shipping labels."
966
  msgstr ""
967
 
968
+ #: dist/woocommerce-services-1.22.4.js:107
969
  msgctxt ""
970
  "This section displays the overall health of WooCommerce Services and the "
971
  "things it depends on"
972
  msgid "Health"
973
  msgstr ""
974
 
975
+ #: dist/woocommerce-services-1.22.4.js:107
976
  msgid "Last updated %s. {{a}}Refresh{{/a}}"
977
  msgstr ""
978
 
979
+ #: dist/woocommerce-services-1.22.4.js:107
980
  msgid "Refresh"
981
  msgstr ""
982
 
983
+ #: dist/woocommerce-services-1.22.4.js:107
984
  msgid "WooCommerce"
985
  msgstr ""
986
 
987
+ #: dist/woocommerce-services-1.22.4.js:107
988
  msgid "Jetpack"
989
  msgstr ""
990
 
991
+ #: dist/woocommerce-services-1.22.4.js:107
992
  msgid "WooCommerce Services Data"
993
  msgstr ""
994
 
995
+ #: dist/woocommerce-services-1.22.4.js:107
996
  msgid "Log tail copied to clipboard"
997
  msgstr ""
998
 
999
+ #: dist/woocommerce-services-1.22.4.js:107
1000
  msgid "Last %s entry. {{a}}Show full log{{/a}}"
1001
  msgid_plural "Last %s entries. {{a}}Show full log{{/a}}"
1002
  msgstr[0] ""
1003
  msgstr[1] ""
1004
 
1005
+ #: dist/woocommerce-services-1.22.4.js:107
1006
  msgid "Copy for support"
1007
  msgstr ""
1008
 
1009
+ #: dist/woocommerce-services-1.22.4.js:107
1010
  msgid ""
1011
  "Request was made %s - check logs below or {{a}}edit service settings{{/a}}"
1012
  msgstr ""
1013
 
1014
+ #: dist/woocommerce-services-1.22.4.js:107
1015
  msgid "Edit service settings"
1016
  msgstr ""
1017
 
1018
+ #: dist/woocommerce-services-1.22.4.js:107
1019
  msgid "Services"
1020
  msgstr ""
1021
 
1022
+ #: dist/woocommerce-services-1.22.4.js:107
1023
  msgid "No services configured. {{a}}Add a shipping service{{/a}}"
1024
  msgstr ""
1025
 
1026
+ #: dist/woocommerce-services-1.22.4.js:107
1027
  msgid "Debug"
1028
  msgstr ""
1029
 
1030
+ #: dist/woocommerce-services-1.22.4.js:107
1031
  msgid "Display troubleshooting information on the Cart and Checkout pages."
1032
  msgstr ""
1033
 
1034
+ #: dist/woocommerce-services-1.22.4.js:107
1035
  msgid "Enabled"
1036
  msgstr ""
1037
 
1038
+ #: dist/woocommerce-services-1.22.4.js:107
1039
  msgid "Disabled"
1040
  msgstr ""
1041
 
1042
+ #: dist/woocommerce-services-1.22.4.js:107
1043
  msgid "Logging"
1044
  msgstr ""
1045
 
1046
+ #: dist/woocommerce-services-1.22.4.js:107
1047
  msgid ""
1048
  "Write diagnostic messages to log files. Helpful when contacting support."
1049
  msgstr ""
1050
 
1051
+ #: dist/woocommerce-services-1.22.4.js:107
1052
  msgid "Shipping Log"
1053
  msgstr ""
1054
 
1055
+ #: dist/woocommerce-services-1.22.4.js:107
1056
  msgid "Taxes Log"
1057
  msgstr ""
1058
 
1059
+ #: dist/woocommerce-services-1.22.4.js:107
1060
  msgid "Other Log"
1061
  msgstr ""
1062
 
1063
+ #: dist/woocommerce-services-1.22.4.js:107
1064
  msgid "Support"
1065
  msgstr ""
1066
 
1067
+ #: dist/woocommerce-services-1.22.4.js:107
1068
  msgid "Need help?"
1069
  msgstr ""
1070
 
1071
+ #: dist/woocommerce-services-1.22.4.js:107
1072
  msgid ""
1073
  "Our team is here for you. View our {{docsA}}support docs{{/docsA}} or "
1074
  "{{ticketA}}open a support ticket{{/ticketA}}."
1075
  msgstr ""
1076
 
1077
+ #: dist/woocommerce-services-1.22.4.js:107
1078
  msgid "Activated"
1079
  msgstr ""
1080
 
1081
+ #: dist/woocommerce-services-1.22.4.js:107
1082
  msgid "Check email to activate account"
1083
  msgstr ""
1084
 
1085
+ #: dist/woocommerce-services-1.22.4.js:107
1086
  msgid "Disconnecting"
1087
  msgstr ""
1088
 
1089
+ #: dist/woocommerce-services-1.22.4.js:107
1090
  msgid "Disconnect"
1091
  msgstr ""
1092
 
1093
+ #: dist/woocommerce-services-1.22.4.js:107
1094
  msgid "Stripe account"
1095
  msgstr ""
1096
 
1097
+ #: dist/woocommerce-services-1.22.4.js:107
1098
  msgid "Account disconnected. Reloading page…"
1099
  msgstr ""
1100
 
1101
+ #: dist/woocommerce-services-1.22.4.js:107
1102
  msgid ""
1103
  "You’ve got WooCommerce Services installed. If you’d like, we can "
1104
  "automatically copy keys from your Stripe account for you. {{a}}Click here{{/"
i18n/strings.php CHANGED
@@ -1,299 +1,299 @@
1
  <?php
2
  /* THIS IS A GENERATED FILE. DO NOT EDIT DIRECTLY. */
3
  $i18nStrings = array(
4
- __( "Dismiss", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
5
- __( "Required", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
6
- __( "Optional", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
7
- __( "More", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
8
- __( "All services selected", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
9
- _n( "%(numSelected)d service selected", "%(numSelected)d services selected", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
10
- __( "Expand Services", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
11
- __( "Service", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
12
- __( "Price adjustment", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
13
- __( "Increase the rates calculated by the carrier to account for packaging and handling costs. You can also add a negative amount to save your customers money.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
14
- __( "Saved Packages", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
15
- __( "Add and edit saved packages using the {{a}}Packaging Manager{{/a}}.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
16
- __( "You have unsaved changes.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
17
- __( "Your changes have been saved.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
18
- __( "There was a problem with one or more entries. Please fix the errors below and try saving again.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
19
- __( "Save changes", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
20
- __( "Saving…", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
21
- __( "Save Settings", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
22
- __( "We have slightly modified the address entered. If correct, please use the suggested address to ensure accurate delivery.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
23
- __( "Address entered", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
24
- __( "Suggested address", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
25
- __( "Use selected address", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
26
- __( "Edit address", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
27
- __( "We were unable to automatically verify the address — %(error)s.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
28
- __( "We were unable to automatically verify the address.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
29
- __( "Address entered", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
30
- __( "Automatic verification failed for this address. It may still be a valid address — use the tools below to manually verify.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
31
- __( "Verify with USPS", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
32
- __( "View on Google Maps", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
33
- __( "Edit address", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
34
- __( "Use address as entered", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
35
- __( "Name", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
36
- __( "Company", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
37
- __( "Phone", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
38
- __( "%(message)s. Please modify the address and try again.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
39
- __( "Address", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
40
- __( "City", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
41
- __( "State", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
42
- __( "Select one…", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
43
- __( "State", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
44
- __( "Postal code", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
45
- __( "Country", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
46
- __( "Verify address", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
47
- __( "Use address as entered", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
48
- __( "Expand", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
49
- __( "Validating address…", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
50
- __( "Invalid address", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
51
- __( "You've edited the address, please revalidate it for accurate rates", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
52
- __( "Packages to be Shipped", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
53
- __( "Move", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
54
  /* translators: Length placeholder for dimensions input */
55
- __( "L", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
56
  /* translators: Width placeholder for dimensions input */
57
- __( "W", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
58
  /* translators: Height placeholder for dimensions input */
59
- __( "H", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
60
- __( "Invalid value.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
61
- __( "This field is required.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
62
- __( "Type of package", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
63
- __( "Box", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
64
- __( "Envelope", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
65
- __( "Package name", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
66
- __( "Unique package name", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
67
- __( "This field must be unique", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
68
- __( "Dimensions (L x W x H)", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
69
- __( "Weight of empty package", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
70
- __( "0.0", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
71
- __( "Untitled", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
72
- __( "All packages selected", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
73
- _n( "%(selectedCount)d package selected", "%(selectedCount)d packages selected", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
74
- __( "Expand Services", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
75
- __( "Your shipping packages have been saved.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
76
- __( "Unable to save your shipping packages. Please try again.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
77
- _n( "Add package", "Add packages", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
78
- __( "Done", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
79
- __( "Cancel", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
80
- __( "{{icon/}} Delete this package", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
81
- __( "Individually Shipped Item", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
82
- __( "Item Dimensions", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
83
- __( "Package details", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
84
- __( "Add package", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
85
- __( "Select a package type", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
86
- __( "Please select a package", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
87
- __( "Add items", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
88
- __( "Items to fulfill", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
89
- __( "Weight", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
90
- __( "QTY", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
91
- __( "There are no items in this package.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
92
- __( "Total Weight (with package)", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
93
- __( "0", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
94
- __( "{{itemLink/}} is currently saved for a later shipment.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
95
- __( "{{itemLink/}} is currently shipped in its original packaging.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
96
- __( "{{itemLink/}} is currently in {{pckg/}}.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
97
- __( "Cancel", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
98
- __( "Submit", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
99
- __( "Move item", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
100
- __( "Where would you like to move it?", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
101
- __( "Add to a New Package", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
102
- __( "Ship in original packaging", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
103
- __( "Remove from package", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
104
- __( "%(item)s from {{pckg/}}", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
105
- __( "Close", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
106
- __( "Add", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
107
- __( "Add item", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
108
- __( "Which items would you like to add to {{pckg/}}?", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
109
- __( "Packaging", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
110
- __( "No packages selected", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
111
- __( "1 item in 1 package: %(weight)s %(unit)s total", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
112
- __( "%(itemsCount)d items in 1 package: %(weight)s %(unit)s total", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
113
- __( "%(itemsCount)d items in %(packageCount)d packages: %(weight)s %(unit)s total", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
114
- __( "Use these packages", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
115
- __( "HS Tariff number", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
116
- __( "more info", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
117
- __( "Origin country", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
118
- __( "Country where the product was manufactured or assembled", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
119
- __( "Description", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
120
- __( "Weight (%s per unit)", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
121
- __( "Value ($ per unit)", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
122
- __( "Description", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
123
- __( "Optional", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
124
- __( "Weight (per unit)", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
125
- __( "Value (per unit)", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
126
- __( "Return to sender if package is unable to be delivered", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
127
- __( "Contents type", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
128
- __( "Merchandise", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
129
- __( "Documents", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
130
- __( "Gift", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
131
- __( "Sample", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
132
- __( "Other…", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
133
- __( "Details", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
134
- __( "Restriction type", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
135
- __( "None", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
136
- __( "Quarantine", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
137
- __( "Sanitary / Phytosanitary inspection", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
138
- __( "Other…", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
139
- __( "Details", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
140
- __( "ITN", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
141
- __( "more info", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
142
- __( "Customs information incomplete", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
143
- __( "Customs information valid", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
144
- __( "Customs", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
145
- __( "Save customs form", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
146
- __( "The service and rate chosen by the customer at checkout is not available. Please choose another.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
147
- __( "Choose rate: %(pckg)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
148
- __( "Unsaved changes made to packages", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
149
- __( "No rates found", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
150
- __( "%(serviceName)s: %(rate)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
151
- __( "Total rate: %(total)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
152
- __( "Shipping rates", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
153
- __( "Customer paid a {{shippingMethod/}} of {{shippingCost/}} for shipping", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
154
- __( "Your customer selected {{shippingMethod/}}", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
155
- __( "WooCommerce Services gives you access to USPS Commercial Pricing, which is discounted over Retail rates.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
156
- __( "Package %(index)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
157
- __( "You save", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
158
- __( "Total", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
159
- __( "Shipping summary", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
160
- __( "Shipping from", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
161
- __( "Edit", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
162
- _n( "shipping label ready", "shipping labels ready", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
163
- __( "Print", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
164
- __( "Purchasing…", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
165
- __( "Buy shipping labels", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
166
- __( "Choose credit card", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
167
- __( "To print this shipping label, {{a}}choose a credit card to your account{{/a}}.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
168
- __( "Add credit card", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
169
- __( "To print this shipping label, {{a}}add a credit card to your account{{/a}}.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
170
- __( "Email shipment details to the customer", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
171
- __( "Mark the order as fulfilled", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
172
- __( "Paper size", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
173
- __( "Create shipping label", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
174
- __( "Create shipping labels", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
175
- __( "Origin address", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
176
- __( "Destination address", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
177
- __( "Toggle menu", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
178
- __( "Cancel", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
179
- __( "Refund label (-%(amount)s)", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
180
- __( "Request a refund", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
181
- __( "You can request a refund for a shipping label that has not been used to ship a package. It will take at least 14 days to process.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
182
- __( "Purchase date", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
183
- __( "Amount eligible for refund", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
184
- __( "Cancel", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
185
- __( "Print", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
186
- __( "Reprint shipping label", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
187
- __( "If there was a printing error when you purchased the label, you can print it again.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
188
- __( "NOTE: If you already used the label in a package, printing and using it again is a violation of our terms of service and may result in criminal charges.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
189
- __( "Paper size", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
190
- __( "Close", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
191
- __( "Label #%(labelIndex)s details", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
192
- __( "Receipt", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
193
- __( "Service", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
194
- __( "Package", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
195
- __( "Items", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
196
- __( "N/A", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
197
- __( "Request refund", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
198
- __( "Reprint", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
199
- __( "View details", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
200
- __( "%(service)s label (#%(labelIndex)d)", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
201
- __( "Tracking #: {{trackingLink/}}", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
202
- __( "%(service)s label (#%(labelIndex)d)", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
203
- __( "Purchasing…", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
204
- __( "Internal note", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
205
- __( "Note sent to customer", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
206
- __( "%(service)s label (#%(labelNum)d) refund requested (%(amount)s)", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
207
- __( "%(service)s label (#%(labelNum)d) refunded (%(amount)s)", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
208
- __( "%(service)s label (#%(labelNum)d) refund rejected", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
209
- __( "Refund", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
210
- __( "Refunded %(amount)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
211
- __( "Note", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
212
- _n( "%(count)s event", "%(count)s events", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
213
- __( "Show notes from %(date)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
214
- __( "No activity yet", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
215
- __( "Which package would you like to track?", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
216
- __( "Create shipping label", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
217
- __( "Track Packages", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
218
- __( "Create new label", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
219
- __( "Track Packages", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
220
- __( "Create shipping label", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
221
- __( "Connection error: unable to create label at this time", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
222
- _n( "item is ready for shipment", "items are ready for shipment", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
223
- __( "No tracking information available at this time", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
224
  /* translators: Name for WeChat Pay - https://pay.weixin.qq.com/ */
225
- __( "WeChat Pay", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
226
- __( "American Express", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
227
- __( "Discover", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
228
- __( "MasterCard", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
229
- __( "VISA", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
230
- __( "PayPal", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
231
- __( "%(card)s ****%(digits)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
232
- _x( "Expires %(date)s", "date is of the form MM/YY", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
233
- __( "Only the site owner can manage shipping label payment methods. Please contact %(ownerName)s (%(ownerLogin)s) to manage payment methods.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
234
- __( "Retry", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
235
- __( "Only the site owner can change these settings. Please contact %(ownerName)s (%(ownerLogin)s) to change the shipping label settings.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
236
- __( "Credit cards are retrieved from the following WordPress.com account: %(wpcomLogin)s <%(wpcomEmail)s>", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
237
- __( "We'll charge the credit card on your account (%(card)s) to pay for the labels you print", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
238
- __( "To purchase shipping labels, add a credit card.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
239
- __( "Choose a different card", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
240
- __( "To purchase shipping labels, choose a credit card you have on file or add a new card.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
241
- __( "Add another credit card", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
242
- __( "To purchase shipping labels, add a credit card.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
243
- __( "Add a credit card", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
244
- __( "Email Receipts", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
245
- __( "Email the label purchase receipts to %(ownerName)s (%(ownerLogin)s) at %(ownerEmail)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
246
- __( "Paper size", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
247
- __( "Payment", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
248
- __( "Unable to get your settings. Please refresh the page to try again.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
249
- __( "Shipping Labels", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
250
- __( "Print shipping labels yourself and save a trip to the post office.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
251
- __( "Name", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
252
- __( "Dimensions", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
253
- __( "Edit", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
254
- __( "Remove", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
255
- __( "Packaging", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
256
- __( "Add boxes, envelopes, and other packages you use most frequently.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
257
- __( "Add package", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
258
- __( "Return to Order #%(orderId)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
259
- __( "Your shipping settings have been saved.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
260
- __( "Unable to save your shipping settings. Please try again.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
261
- __( "A payment method is required to print shipping labels.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
262
- __( "Save changes", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
263
- _x( "Health", "This section displays the overall health of WooCommerce Services and the things it depends on", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
264
- __( "Last updated %s. {{a}}Refresh{{/a}}", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
265
- __( "Refresh", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
266
- __( "WooCommerce", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
267
- __( "Jetpack", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
268
- __( "WooCommerce Services Data", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
269
- __( "Log tail copied to clipboard", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
270
- _n( "Last %s entry. {{a}}Show full log{{/a}}", "Last %s entries. {{a}}Show full log{{/a}}", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
271
- __( "Copy for support", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
272
- __( "Request was made %s - check logs below or {{a}}edit service settings{{/a}}", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
273
- __( "Edit service settings", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
274
- __( "Services", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
275
- __( "No services configured. {{a}}Add a shipping service{{/a}}", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
276
- __( "Debug", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
277
- __( "Debug", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
278
- __( "Display troubleshooting information on the Cart and Checkout pages.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
279
- __( "Enabled", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
280
- __( "Disabled", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
281
- __( "Logging", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
282
- __( "Write diagnostic messages to log files. Helpful when contacting support.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
283
- __( "Enabled", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
284
- __( "Disabled", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
285
- __( "Shipping Log", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
286
- __( "Taxes Log", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
287
- __( "Other Log", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
288
- __( "Support", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
289
- __( "Need help?", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
290
- __( "Our team is here for you. View our {{docsA}}support docs{{/docsA}} or {{ticketA}}open a support ticket{{/ticketA}}.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
291
- __( "Activated", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
292
- __( "Check email to activate account", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
293
- __( "Disconnecting", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
294
- __( "Disconnect", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
295
- __( "Stripe account", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
296
- __( "Account disconnected. Reloading page…", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
297
- __( "You’ve got WooCommerce Services installed. If you’d like, we can automatically copy keys from your Stripe account for you. {{a}}Click here{{/a}} to connect your Stripe account using WooCommerce Services.", "woocommerce-services" ), // dist/woocommerce-services-1.22.3.js:107
298
  );
299
  /* THIS IS THE END OF THE GENERATED FILE */
1
  <?php
2
  /* THIS IS A GENERATED FILE. DO NOT EDIT DIRECTLY. */
3
  $i18nStrings = array(
4
+ __( "Dismiss", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
5
+ __( "Required", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
6
+ __( "Optional", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
7
+ __( "More", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
8
+ __( "All services selected", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
9
+ _n( "%(numSelected)d service selected", "%(numSelected)d services selected", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
10
+ __( "Expand Services", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
11
+ __( "Service", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
12
+ __( "Price adjustment", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
13
+ __( "Increase the rates calculated by the carrier to account for packaging and handling costs. You can also add a negative amount to save your customers money.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
14
+ __( "Saved Packages", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
15
+ __( "Add and edit saved packages using the {{a}}Packaging Manager{{/a}}.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
16
+ __( "You have unsaved changes.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
17
+ __( "Your changes have been saved.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
18
+ __( "There was a problem with one or more entries. Please fix the errors below and try saving again.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
19
+ __( "Save changes", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
20
+ __( "Saving…", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
21
+ __( "Save Settings", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
22
+ __( "We have slightly modified the address entered. If correct, please use the suggested address to ensure accurate delivery.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
23
+ __( "Address entered", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
24
+ __( "Suggested address", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
25
+ __( "Use selected address", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
26
+ __( "Edit address", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
27
+ __( "We were unable to automatically verify the address — %(error)s.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
28
+ __( "We were unable to automatically verify the address.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
29
+ __( "Address entered", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
30
+ __( "Automatic verification failed for this address. It may still be a valid address — use the tools below to manually verify.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
31
+ __( "Verify with USPS", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
32
+ __( "View on Google Maps", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
33
+ __( "Edit address", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
34
+ __( "Use address as entered", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
35
+ __( "Name", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
36
+ __( "Company", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
37
+ __( "Phone", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
38
+ __( "%(message)s. Please modify the address and try again.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
39
+ __( "Address", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
40
+ __( "City", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
41
+ __( "State", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
42
+ __( "Select one…", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
43
+ __( "State", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
44
+ __( "Postal code", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
45
+ __( "Country", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
46
+ __( "Verify address", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
47
+ __( "Use address as entered", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
48
+ __( "Expand", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
49
+ __( "Validating address…", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
50
+ __( "Invalid address", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
51
+ __( "You've edited the address, please revalidate it for accurate rates", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
52
+ __( "Packages to be Shipped", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
53
+ __( "Move", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
54
  /* translators: Length placeholder for dimensions input */
55
+ __( "L", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
56
  /* translators: Width placeholder for dimensions input */
57
+ __( "W", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
58
  /* translators: Height placeholder for dimensions input */
59
+ __( "H", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
60
+ __( "Invalid value.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
61
+ __( "This field is required.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
62
+ __( "Type of package", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
63
+ __( "Box", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
64
+ __( "Envelope", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
65
+ __( "Package name", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
66
+ __( "Unique package name", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
67
+ __( "This field must be unique", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
68
+ __( "Dimensions (L x W x H)", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
69
+ __( "Weight of empty package", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
70
+ __( "0.0", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
71
+ __( "Untitled", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
72
+ __( "All packages selected", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
73
+ _n( "%(selectedCount)d package selected", "%(selectedCount)d packages selected", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
74
+ __( "Expand Services", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
75
+ __( "Your shipping packages have been saved.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
76
+ __( "Unable to save your shipping packages. Please try again.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
77
+ _n( "Add package", "Add packages", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
78
+ __( "Done", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
79
+ __( "Cancel", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
80
+ __( "{{icon/}} Delete this package", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
81
+ __( "Individually Shipped Item", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
82
+ __( "Item Dimensions", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
83
+ __( "Package details", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
84
+ __( "Add package", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
85
+ __( "Select a package type", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
86
+ __( "Please select a package", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
87
+ __( "Add items", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
88
+ __( "Items to fulfill", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
89
+ __( "Weight", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
90
+ __( "QTY", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
91
+ __( "There are no items in this package.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
92
+ __( "Total Weight (with package)", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
93
+ __( "0", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
94
+ __( "{{itemLink/}} is currently saved for a later shipment.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
95
+ __( "{{itemLink/}} is currently shipped in its original packaging.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
96
+ __( "{{itemLink/}} is currently in {{pckg/}}.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
97
+ __( "Cancel", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
98
+ __( "Submit", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
99
+ __( "Move item", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
100
+ __( "Where would you like to move it?", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
101
+ __( "Add to a New Package", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
102
+ __( "Ship in original packaging", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
103
+ __( "Remove from package", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
104
+ __( "%(item)s from {{pckg/}}", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
105
+ __( "Close", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
106
+ __( "Add", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
107
+ __( "Add item", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
108
+ __( "Which items would you like to add to {{pckg/}}?", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
109
+ __( "Packaging", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
110
+ __( "No packages selected", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
111
+ __( "1 item in 1 package: %(weight)s %(unit)s total", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
112
+ __( "%(itemsCount)d items in 1 package: %(weight)s %(unit)s total", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
113
+ __( "%(itemsCount)d items in %(packageCount)d packages: %(weight)s %(unit)s total", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
114
+ __( "Use these packages", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
115
+ __( "HS Tariff number", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
116
+ __( "more info", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
117
+ __( "Origin country", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
118
+ __( "Country where the product was manufactured or assembled", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
119
+ __( "Description", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
120
+ __( "Weight (%s per unit)", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
121
+ __( "Value ($ per unit)", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
122
+ __( "Description", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
123
+ __( "Optional", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
124
+ __( "Weight (per unit)", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
125
+ __( "Value (per unit)", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
126
+ __( "Return to sender if package is unable to be delivered", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
127
+ __( "Contents type", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
128
+ __( "Merchandise", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
129
+ __( "Documents", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
130
+ __( "Gift", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
131
+ __( "Sample", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
132
+ __( "Other…", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
133
+ __( "Details", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
134
+ __( "Restriction type", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
135
+ __( "None", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
136
+ __( "Quarantine", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
137
+ __( "Sanitary / Phytosanitary inspection", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
138
+ __( "Other…", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
139
+ __( "Details", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
140
+ __( "ITN", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
141
+ __( "more info", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
142
+ __( "Customs information incomplete", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
143
+ __( "Customs information valid", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
144
+ __( "Customs", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
145
+ __( "Save customs form", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
146
+ __( "The service and rate chosen by the customer at checkout is not available. Please choose another.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
147
+ __( "Choose rate: %(pckg)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
148
+ __( "Unsaved changes made to packages", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
149
+ __( "No rates found", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
150
+ __( "%(serviceName)s: %(rate)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
151
+ __( "Total rate: %(total)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
152
+ __( "Shipping rates", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
153
+ __( "Customer paid a {{shippingMethod/}} of {{shippingCost/}} for shipping", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
154
+ __( "Your customer selected {{shippingMethod/}}", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
155
+ __( "WooCommerce Services gives you access to USPS Commercial Pricing, which is discounted over Retail rates.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
156
+ __( "Package %(index)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
157
+ __( "You save", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
158
+ __( "Total", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
159
+ __( "Shipping summary", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
160
+ __( "Shipping from", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
161
+ __( "Edit", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
162
+ _n( "shipping label ready", "shipping labels ready", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
163
+ __( "Print", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
164
+ __( "Purchasing…", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
165
+ __( "Buy shipping labels", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
166
+ __( "Choose credit card", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
167
+ __( "To print this shipping label, {{a}}choose a credit card to your account{{/a}}.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
168
+ __( "Add credit card", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
169
+ __( "To print this shipping label, {{a}}add a credit card to your account{{/a}}.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
170
+ __( "Email shipment details to the customer", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
171
+ __( "Mark the order as fulfilled", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
172
+ __( "Paper size", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
173
+ __( "Create shipping label", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
174
+ __( "Create shipping labels", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
175
+ __( "Origin address", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
176
+ __( "Destination address", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
177
+ __( "Toggle menu", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
178
+ __( "Cancel", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
179
+ __( "Refund label (-%(amount)s)", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
180
+ __( "Request a refund", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
181
+ __( "You can request a refund for a shipping label that has not been used to ship a package. It will take at least 14 days to process.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
182
+ __( "Purchase date", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
183
+ __( "Amount eligible for refund", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
184
+ __( "Cancel", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
185
+ __( "Print", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
186
+ __( "Reprint shipping label", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
187
+ __( "If there was a printing error when you purchased the label, you can print it again.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
188
+ __( "NOTE: If you already used the label in a package, printing and using it again is a violation of our terms of service and may result in criminal charges.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
189
+ __( "Paper size", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
190
+ __( "Close", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
191
+ __( "Label #%(labelIndex)s details", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
192
+ __( "Receipt", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
193
+ __( "Service", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
194
+ __( "Package", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
195
+ __( "Items", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
196
+ __( "N/A", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
197
+ __( "Request refund", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
198
+ __( "Reprint", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
199
+ __( "View details", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
200
+ __( "%(service)s label (#%(labelIndex)d)", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
201
+ __( "Tracking #: {{trackingLink/}}", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
202
+ __( "%(service)s label (#%(labelIndex)d)", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
203
+ __( "Purchasing…", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
204
+ __( "Internal note", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
205
+ __( "Note sent to customer", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
206
+ __( "%(service)s label (#%(labelNum)d) refund requested (%(amount)s)", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
207
+ __( "%(service)s label (#%(labelNum)d) refunded (%(amount)s)", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
208
+ __( "%(service)s label (#%(labelNum)d) refund rejected", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
209
+ __( "Refund", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
210
+ __( "Refunded %(amount)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
211
+ __( "Note", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
212
+ _n( "%(count)s event", "%(count)s events", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
213
+ __( "Show notes from %(date)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
214
+ __( "No activity yet", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
215
+ __( "Which package would you like to track?", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
216
+ __( "Create shipping label", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
217
+ __( "Track Packages", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
218
+ __( "Create new label", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
219
+ __( "Track Packages", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
220
+ __( "Create shipping label", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
221
+ __( "Connection error: unable to create label at this time", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
222
+ _n( "item is ready for shipment", "items are ready for shipment", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
223
+ __( "No tracking information available at this time", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
224
  /* translators: Name for WeChat Pay - https://pay.weixin.qq.com/ */
225
+ __( "WeChat Pay", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
226
+ __( "American Express", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
227
+ __( "Discover", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
228
+ __( "MasterCard", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
229
+ __( "VISA", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
230
+ __( "PayPal", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
231
+ __( "%(card)s ****%(digits)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
232
+ _x( "Expires %(date)s", "date is of the form MM/YY", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
233
+ __( "Only the site owner can manage shipping label payment methods. Please contact %(ownerName)s (%(ownerLogin)s) to manage payment methods.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
234
+ __( "Retry", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
235
+ __( "Only the site owner can change these settings. Please contact %(ownerName)s (%(ownerLogin)s) to change the shipping label settings.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
236
+ __( "Credit cards are retrieved from the following WordPress.com account: %(wpcomLogin)s <%(wpcomEmail)s>", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
237
+ __( "We'll charge the credit card on your account (%(card)s) to pay for the labels you print", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
238
+ __( "To purchase shipping labels, add a credit card.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
239
+ __( "Choose a different card", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
240
+ __( "To purchase shipping labels, choose a credit card you have on file or add a new card.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
241
+ __( "Add another credit card", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
242
+ __( "To purchase shipping labels, add a credit card.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
243
+ __( "Add a credit card", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
244
+ __( "Email Receipts", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
245
+ __( "Email the label purchase receipts to %(ownerName)s (%(ownerLogin)s) at %(ownerEmail)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
246
+ __( "Paper size", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
247
+ __( "Payment", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
248
+ __( "Unable to get your settings. Please refresh the page to try again.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
249
+ __( "Shipping Labels", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
250
+ __( "Print shipping labels yourself and save a trip to the post office.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
251
+ __( "Name", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
252
+ __( "Dimensions", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
253
+ __( "Edit", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
254
+ __( "Remove", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
255
+ __( "Packaging", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
256
+ __( "Add boxes, envelopes, and other packages you use most frequently.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
257
+ __( "Add package", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
258
+ __( "Return to Order #%(orderId)s", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
259
+ __( "Your shipping settings have been saved.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
260
+ __( "Unable to save your shipping settings. Please try again.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
261
+ __( "A payment method is required to print shipping labels.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
262
+ __( "Save changes", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
263
+ _x( "Health", "This section displays the overall health of WooCommerce Services and the things it depends on", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
264
+ __( "Last updated %s. {{a}}Refresh{{/a}}", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
265
+ __( "Refresh", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
266
+ __( "WooCommerce", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
267
+ __( "Jetpack", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
268
+ __( "WooCommerce Services Data", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
269
+ __( "Log tail copied to clipboard", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
270
+ _n( "Last %s entry. {{a}}Show full log{{/a}}", "Last %s entries. {{a}}Show full log{{/a}}", 1, "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
271
+ __( "Copy for support", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
272
+ __( "Request was made %s - check logs below or {{a}}edit service settings{{/a}}", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
273
+ __( "Edit service settings", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
274
+ __( "Services", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
275
+ __( "No services configured. {{a}}Add a shipping service{{/a}}", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
276
+ __( "Debug", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
277
+ __( "Debug", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
278
+ __( "Display troubleshooting information on the Cart and Checkout pages.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
279
+ __( "Enabled", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
280
+ __( "Disabled", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
281
+ __( "Logging", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
282
+ __( "Write diagnostic messages to log files. Helpful when contacting support.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
283
+ __( "Enabled", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
284
+ __( "Disabled", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
285
+ __( "Shipping Log", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
286
+ __( "Taxes Log", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
287
+ __( "Other Log", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
288
+ __( "Support", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
289
+ __( "Need help?", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
290
+ __( "Our team is here for you. View our {{docsA}}support docs{{/docsA}} or {{ticketA}}open a support ticket{{/ticketA}}.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
291
+ __( "Activated", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
292
+ __( "Check email to activate account", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
293
+ __( "Disconnecting", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
294
+ __( "Disconnect", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
295
+ __( "Stripe account", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
296
+ __( "Account disconnected. Reloading page…", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
297
+ __( "You’ve got WooCommerce Services installed. If you’d like, we can automatically copy keys from your Stripe account for you. {{a}}Click here{{/a}} to connect your Stripe account using WooCommerce Services.", "woocommerce-services" ), // dist/woocommerce-services-1.22.4.js:107
298
  );
299
  /* THIS IS THE END OF THE GENERATED FILE */
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: shipping, stamps, usps, woocommerce, taxes, payment, stripe
4
  Requires at least: 4.6
5
  Requires PHP: 5.3
6
  Tested up to: 5.3
7
- Stable tag: 1.22.3
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -83,6 +83,10 @@ As of the WooCommerce 3.5 release, WooCommerce Services no longer provides shipp
83
 
84
  == Changelog ==
85
 
 
 
 
 
86
  = 1.22.3 - 2020-01-22 =
87
  * Add - Preselect rate when there is only one rate available for given shipping configuration.
88
  * Add - Paper size selection into purchase modal sidebar and reprint modal which was previously removed.
4
  Requires at least: 4.6
5
  Requires PHP: 5.3
6
  Tested up to: 5.3
7
+ Stable tag: 1.22.4
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
83
 
84
  == Changelog ==
85
 
86
+ = 1.22.4 - 2020-03-02 =
87
+ * Fix - Stop using deprecated method Jetpack::is_staging_site() when Jetpack
88
+ 8.1 is installed.
89
+
90
  = 1.22.3 - 2020-01-22 =
91
  * Add - Preselect rate when there is only one rate available for given shipping configuration.
92
  * Add - Paper size selection into purchase modal sidebar and reprint modal which was previously removed.
trunk/classes/class-wc-connect-api-client.php ADDED
@@ -0,0 +1,682 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // No direct access please
4
+ if ( ! defined( 'ABSPATH' ) ) {
5
+ exit;
6
+ }
7
+
8
+ if ( ! defined( 'WOOCOMMERCE_CONNECT_SERVER_URL' ) ) {
9
+ define( 'WOOCOMMERCE_CONNECT_SERVER_URL', 'https://api.woocommerce.com/' );
10
+ }
11
+
12
+ if ( ! class_exists( 'WC_Connect_API_Client' ) ) {
13
+
14
+ class WC_Connect_API_Client {
15
+
16
+ /**
17
+ * @var WC_Connect_Services_Validator
18
+ */
19
+ protected $validator;
20
+
21
+ /**
22
+ * @var WC_Connect_Loader
23
+ */
24
+ protected $wc_connect_loader;
25
+
26
+ public function __construct(
27
+ WC_Connect_Service_Schemas_Validator $validator,
28
+ WC_Connect_Loader $wc_connect_loader
29
+ ) {
30
+
31
+ $this->validator = $validator;
32
+ $this->wc_connect_loader = $wc_connect_loader;
33
+
34
+ }
35
+
36
+ /**
37
+ * Requests the available services for this site from the WooCommerce Services Server
38
+ *
39
+ * @return array|WP_Error
40
+ */
41
+ public function get_service_schemas() {
42
+ $response_body = $this->request( 'POST', '/services' );
43
+
44
+ if ( is_wp_error( $response_body ) ) {
45
+ return $response_body;
46
+ }
47
+
48
+ $result = $this->validator->validate_service_schemas( $response_body );
49
+ if ( is_wp_error( $result ) ) {
50
+ return $result;
51
+ }
52
+
53
+ return $response_body;
54
+ }
55
+
56
+ /**
57
+ * Validates the settings for a given service with the WooCommerce Services Server
58
+ *
59
+ * @param $service_slug
60
+ * @param $service_settings
61
+ *
62
+ * @return bool|WP_Error
63
+ */
64
+ public function validate_service_settings( $service_slug, $service_settings ) {
65
+ // Make sure the service slug only contains underscores or letters
66
+ if ( 1 === preg_match( '/[^a-z_]/i', $service_slug ) ) {
67
+ return new WP_Error( 'invalid_service_slug', __( 'Invalid WooCommerce Services service slug provided', 'woocommerce-services' ) );
68
+ }
69
+
70
+ return $this->request( 'POST', "/services/{$service_slug}/settings", array( 'service_settings' => $service_settings ) );
71
+ }
72
+
73
+ /**
74
+ * Build the server's expected contents array, for rates requests.
75
+ *
76
+ * @param $package Package provided to WC_Shipping_Method::calculate_shipping()
77
+ *
78
+ * @return array|WP_Error {
79
+ * @type float $height Product height.
80
+ * @type float $width Product width.
81
+ * @type float $length Product length.
82
+ * @type int $product_id Product ID (or Variation ID).
83
+ * @type int $quantity Quantity of product in shipment.
84
+ * @type float $weight Product weight.
85
+ * }
86
+ */
87
+ public function build_shipment_contents( $package ) {
88
+ $contents = array();
89
+
90
+ foreach ( $package[ 'contents' ] as $package_item ) {
91
+ $product = $package_item[ 'data' ];
92
+ $quantity = $package_item[ 'quantity' ];
93
+
94
+ if ( ( $quantity > 0 ) && $product->needs_shipping() ) {
95
+
96
+ if ( ! $product->has_weight() ) {
97
+ return new WP_Error(
98
+ 'product_missing_weight',
99
+ sprintf(
100
+ __( 'Product ( ID: %d ) did not include a weight. Shipping rates cannot be calculated.', 'woocommerce-services' ),
101
+ $product->get_id()
102
+ ),
103
+ array( 'product_id' => $product->get_id() )
104
+ );
105
+ }
106
+
107
+ if (
108
+ ! $product->get_length() ||
109
+ ! $product->get_height() ||
110
+ ! $product->get_width()
111
+ ) {
112
+ return new WP_Error(
113
+ 'product_missing_dimension',
114
+ sprintf(
115
+ __( 'Product ( ID: %d ) is missing a dimension value. Shipping rates cannot be calculated.', 'woocommerce-services' ),
116
+ $product->get_id()
117
+ ),
118
+ array( 'product_id' => $product->get_id() )
119
+ );
120
+ }
121
+
122
+ $weight = $product->get_weight();
123
+ $height = $product->get_height();
124
+ $length = $product->get_length();
125
+ $width = $product->get_width();
126
+
127
+ $contents[] = array(
128
+ 'height' => ( float ) $height,
129
+ 'product_id' => $product->get_id(),
130
+ 'length' => ( float ) $length,
131
+ 'quantity' => $package_item[ 'quantity' ],
132
+ 'weight' => ( float ) $weight,
133
+ 'width' => ( float ) $width,
134
+ );
135
+ }
136
+ }
137
+
138
+ return $contents;
139
+ }
140
+
141
+ /**
142
+ * Gets shipping rates (for checkout) from the WooCommerce Services Server
143
+ *
144
+ * @param $services All settings for all services we want rates for
145
+ * @param $package Package provided to WC_Shipping_Method::calculate_shipping()
146
+ * @param $custom_boxes array of custom boxes definitions (objects)
147
+ * @param $predefined_boxes array of enabled predefined box IDs (strings)
148
+ *
149
+ * @return object|WP_Error
150
+ */
151
+ public function get_shipping_rates( $services, $package, $custom_boxes, $predefined_boxes ) {
152
+ // First, build the contents array
153
+ // each item needs to specify quantity, weight, length, width and height
154
+ $contents = $this->build_shipment_contents( $package );
155
+
156
+ if ( is_wp_error( $contents ) ) {
157
+ return $contents;
158
+ }
159
+
160
+ if ( empty( $contents ) ) {
161
+ return new WP_Error(
162
+ 'nothing_to_ship',
163
+ __( 'No shipping rate could be calculated. No items in the package are shippable.', 'woocommerce-services' )
164
+ );
165
+ }
166
+
167
+ // Then, make the request
168
+ $body = array(
169
+ 'contents' => $contents,
170
+ 'destination' => $package[ 'destination' ],
171
+ 'services' => $services,
172
+ 'boxes' => $custom_boxes,
173
+ 'predefined_boxes' => $predefined_boxes,
174
+ );
175
+
176
+ return $this->request( 'POST', '/shipping/rates', $body );
177
+ }
178
+
179
+ public function send_shipping_label_request( $body ) {
180
+ return $this->request( 'POST', '/shipping/label', $body );
181
+ }
182
+
183
+ public function send_address_normalization_request( $body ) {
184
+ return $this->request( 'POST', '/shipping/address/normalize', $body );
185
+ }
186
+
187
+ /**
188
+ * Asks the WooCommerce Services server for an array of payment methods
189
+ *
190
+ * @return mixed|WP_Error
191
+ */
192
+ public function get_payment_methods() {
193
+ return $this->request( 'POST', '/payment/methods' );
194
+ }
195
+
196
+ /**
197
+ * Gets shipping rates (for labels) from the WooCommerce Services Server
198
+ *
199
+ * @param array $request - array(
200
+ * 'packages' => array(
201
+ * array(
202
+ * 'id' => 'box_1',
203
+ * 'height' => 10,
204
+ * 'length' => 10,
205
+ * 'width' => 10,
206
+ * 'weight' => 10,
207
+ * ),
208
+ * array(
209
+ * 'id' => 'box_2',
210
+ * 'box_id' => 'medium_flat_box_top',
211
+ * 'weight' => 5,
212
+ * ),
213
+ * ...
214
+ * ),
215
+ * 'carrier' => 'usps',
216
+ * 'origin' => array(
217
+ * 'address' => '132 Hawthorne St',
218
+ * 'address_2' => '',
219
+ * 'city' => 'San Francisco',
220
+ * 'state' => 'CA',
221
+ * 'postcode' => '94107',
222
+ * 'country' => 'US',
223
+ * ),
224
+ * 'destination' => array(
225
+ * 'address' => '1550 Snow Creek Dr',
226
+ * 'address_2' => '',
227
+ * 'city' => 'Park City',
228
+ * 'state' => 'UT',
229
+ * 'postcode' => '84060',
230
+ * 'country' => 'US',
231
+ * ),
232
+ * )
233
+ * @return object|WP_Error
234
+ */
235
+ public function get_label_rates( $request ) {
236
+ return $this->request( 'POST', '/shipping/label/rates', $request );
237
+ }
238
+
239
+ /**
240
+ * Gets a PDF with the set of dummy labels specified in the request
241
+ *
242
+ * @param $request
243
+ * @return object|WP_Error
244
+ */
245
+ public function get_labels_preview_pdf( $request ) {
246
+ return $this->request( 'POST', 'shipping/labels/preview', $request );
247
+ }
248
+
249
+ /**
250
+ * Gets a PDF with the requested shipping labels in it
251
+ *
252
+ * @param $request
253
+ * @return object|WP_Error
254
+ */
255
+ public function get_labels_print_pdf( $request ) {
256
+ return $this->request( 'POST', 'shipping/labels/print', $request );
257
+ }
258
+
259
+ /**
260
+ * Gets the shipping label status (refund status, tracking code, etc)
261
+ *
262
+ * @param $label_id integer
263
+ * @return object|WP_Error
264
+ */
265
+ public function get_label_status( $label_id ) {
266
+ return $this->request( 'GET', '/shipping/label/' . $label_id . '?get_refund=true' );
267
+ }
268
+
269
+ /**
270
+ * Gets the shipping label status (refund status, tracking code, etc)
271
+ *
272
+ * @param $order_id integer
273
+ * @return object|WP_Error
274
+ */
275
+ public function anonymize_order( $order_id ) {
276
+ return $this->request( 'POST', '/privacy/order/' . $order_id . '/anonymize' );
277
+ }
278
+
279
+ /**
280
+ * Request a refund for a given shipping label
281
+ *
282
+ * @param $label_id integer
283
+ * @return object|WP_Error
284
+ */
285
+ public function send_shipping_label_refund_request( $label_id ) {
286
+ return $this->request( 'POST', '/shipping/label/' . $label_id . '/refund' );
287
+ }
288
+
289
+ /**
290
+ * Tests the connection to the WooCommerce Services Server
291
+ *
292
+ * @return true|WP_Error
293
+ */
294
+ public function auth_test() {
295
+ return $this->request( 'GET', '/connection/test' );
296
+ }
297
+
298
+ /** Heartbeat test.
299
+ *
300
+ * @return true|WP_Error
301
+ */
302
+ public function is_alive() {
303
+ return $this->request( 'GET', '' );
304
+ }
305
+
306
+ /** Heartbeat test with a transient cache.
307
+ *
308
+ * @return true|WP_Error
309
+ */
310
+ public function is_alive_cached() {
311
+ $connect_server_is_alive_transient = get_transient( 'connect_server_is_alive_transient' );
312
+ if ( false !== $connect_server_is_alive_transient ) {
313
+ return true;
314
+ }
315
+
316
+ $is_alive_request = $this->is_alive();
317
+ $new_is_alive = ! is_wp_error( $is_alive_request );
318
+ if ( $new_is_alive ) {
319
+ set_transient( 'connect_server_is_alive_transient', true, MINUTE_IN_SECONDS );
320
+ }
321
+ return $new_is_alive;
322
+ }
323
+
324
+ /**
325
+ * Create a deferred Stripe Standard Account
326
+ * @param $email string The user's email address
327
+ * @param $country string The user's country
328
+ * @return object|WP_Error
329
+ */
330
+ public function create_stripe_account( $email, $country ) {
331
+ $request = array(
332
+ 'email' => $email,
333
+ 'country' => $country,
334
+ );
335
+ return $this->request( 'POST', '/stripe/account', $request );
336
+ }
337
+
338
+ public function get_stripe_account_details() {
339
+ return $this->request( 'GET', '/stripe/account' );
340
+ }
341
+
342
+ public function get_stripe_oauth_init( $return_url ) {
343
+ $address = $this->wc_connect_loader->get_service_settings_store()->get_origin_address();
344
+ $current_user = wp_get_current_user();
345
+
346
+ $request = array(
347
+ 'returnUrl' => $return_url,
348
+ 'businessData' => array(
349
+ 'url' => get_site_url(),
350
+ 'country' => $address['country'],
351
+ 'phone' => $address['phone'],
352
+ 'business_name' => $address['company'],
353
+ 'first_name' => $current_user->user_firstname,
354
+ 'last_name' => $current_user->user_lastname,
355
+ 'street_address' => $address['address'],
356
+ 'city' => $address['city'],
357
+ 'state' => $address['state'],
358
+ 'zip' => $address['postcode'],
359
+ 'currency' => get_woocommerce_currency(),
360
+ ),
361
+ );
362
+ return $this->request( 'POST', '/stripe/oauth-init', $request );
363
+ }
364
+
365
+ public function get_stripe_oauth_keys( $code ) {
366
+ $request = array(
367
+ 'code' => $code,
368
+ );
369
+ return $this->request( 'POST', '/stripe/oauth-keys', $request );
370
+ }
371
+
372
+ public function deauthorize_stripe_account() {
373
+ return $this->request( 'POST', '/stripe/account/deauthorize' );
374
+ }
375
+ /**
376
+ * Sends a request to the WooCommerce Services Server
377
+ *
378
+ * @param $method
379
+ * @param $path
380
+ * @param $body
381
+ * @return mixed|WP_Error
382
+ */
383
+ protected function request( $method, $path, $body = array() ) {
384
+
385
+ // TODO - incorporate caching for repeated identical requests
386
+ if ( ! class_exists( 'Jetpack_Data' ) ) {
387
+ return new WP_Error(
388
+ 'jetpack_data_class_not_found',
389
+ __( 'Unable to send request to WooCommerce Services server. Jetpack_Data was not found.', 'woocommerce-services' )
390
+ );
391
+ }
392
+
393
+ if ( ! method_exists( 'Jetpack_Data', 'get_access_token' ) ) {
394
+ return new WP_Error(
395
+ 'jetpack_data_get_access_token_not_found',
396
+ __( 'Unable to send request to WooCommerce Services server. Jetpack_Data does not implement get_access_token.', 'woocommerce-services' )
397
+ );
398
+ }
399
+
400
+ if ( ! is_array( $body ) ) {
401
+ return new WP_Error(
402
+ 'request_body_should_be_array',
403
+ __( 'Unable to send request to WooCommerce Services server. Body must be an array.', 'woocommerce-services' )
404
+ );
405
+ }
406
+
407
+ $url = trailingslashit( WOOCOMMERCE_CONNECT_SERVER_URL );
408
+ $url = apply_filters( 'wc_connect_server_url', $url );
409
+ $url = trailingslashit( $url ) . ltrim( $path, '/' );
410
+
411
+ // Add useful system information to requests that contain bodies
412
+ if ( in_array( $method, array( 'POST', 'PUT' ) ) ) {
413
+ $body = $this->request_body( $body );
414
+ $body = wp_json_encode( apply_filters( 'wc_connect_api_client_body', $body ) );
415
+
416
+ if ( ! $body ) {
417
+ return new WP_Error(
418
+ 'unable_to_json_encode_body',
419
+ __( 'Unable to encode body for request to WooCommerce Services server.', 'woocommerce-services' )
420
+ );
421
+ }
422
+ }
423
+
424
+ $headers = $this->request_headers();
425
+ if ( is_wp_error( $headers ) ) {
426
+ return $headers;
427
+ }
428
+
429
+ $http_timeout = 60; // 1 minute
430
+ if ( function_exists( 'wc_set_time_limit' ) ) {
431
+ wc_set_time_limit( $http_timeout + 10 );
432
+ }
433
+ $args = array(
434
+ 'headers' => $headers,
435
+ 'method' => $method,
436
+ 'body' => $body,
437
+ 'redirection' => 0,
438
+ 'compress' => true,
439
+ 'timeout' => $http_timeout,
440
+ );
441
+ $args = apply_filters( 'wc_connect_request_args', $args );
442
+
443
+ $response = wp_remote_request( $url, $args );
444
+ $response_code = wp_remote_retrieve_response_code( $response );
445
+
446
+ // If the received response is not JSON, return the raw response
447
+ $content_type = wp_remote_retrieve_header( $response, 'content-type' );
448
+ if ( false === strpos( $content_type, 'application/json' ) ) {
449
+ if ( 200 != $response_code ) {
450
+ return new WP_Error(
451
+ 'wcc_server_error',
452
+ sprintf(
453
+ __( 'Error: The WooCommerce Services server returned HTTP code: %d', 'woocommerce-services' ),
454
+ $response_code
455
+ )
456
+ );
457
+ }
458
+ return $response;
459
+ }
460
+
461
+ $response_body = wp_remote_retrieve_body( $response );
462
+ if ( ! empty( $response_body ) ) {
463
+ $response_body = json_decode( $response_body );
464
+ }
465
+
466
+ if ( 200 != $response_code ) {
467
+ if ( empty( $response_body ) ) {
468
+ return new WP_Error(
469
+ 'wcc_server_empty_response',
470
+ sprintf(
471
+ __( 'Error: The WooCommerce Services server returned ( %d ) and an empty response body.', 'woocommerce-services' ),
472
+ $response_code
473
+ )
474
+ );
475
+ }
476
+
477
+ $error = property_exists( $response_body, 'error' ) ? $response_body->error : '';
478
+ $message = property_exists( $response_body, 'message' ) ? $response_body->message : '';
479
+ $data = property_exists( $response_body, 'data' ) ? $response_body->data : '';
480
+
481
+ return new WP_Error(
482
+ 'wcc_server_error_response',
483
+ sprintf(
484
+ /* translators: %1$s: error code, %2$s: error message, %3$d: HTTP response code */
485
+ __( 'Error: The WooCommerce Services server returned: %1$s %2$s ( %3$d )', 'woocommerce-services' ),
486
+ $error,
487
+ $message,
488
+ $response_code
489
+ ),
490
+ $data
491
+ );
492
+ }
493
+
494
+ return $response_body;
495
+ }
496
+
497
+ /**
498
+ * Proxy an HTTP request through the WCS Server
499
+ *
500
+ * @param $path Path of proxy route
501
+ * @param $args WP_Http request args
502
+ *
503
+ * @return array|WP_Error
504
+ */
505
+ public function proxy_request( $path, $args ) {
506
+ $proxy_url = trailingslashit( WOOCOMMERCE_CONNECT_SERVER_URL );
507
+ $proxy_url .= ltrim( $path, '/' );
508
+
509
+ $authorization = $this->authorization_header();
510
+ if ( is_wp_error( $authorization ) ) {
511
+ return $authorization;
512
+ }
513
+ $args['headers']['Authorization'] = $authorization;
514
+
515
+
516
+ $http_timeout = 60; // 1 minute
517
+
518
+ if ( function_exists( 'wc_set_time_limit' ) ) {
519
+ wc_set_time_limit( $http_timeout + 10 );
520
+ }
521
+
522
+ $args['timeout'] = $http_timeout;
523
+
524
+ $response = wp_remote_request( $proxy_url, $args );
525
+
526
+ return $response;
527
+ }
528
+
529
+ /**
530
+ * Adds useful WP/WC/WCC information to request bodies
531
+ *
532
+ * @param array $initial_body
533
+ * @return array
534
+ */
535
+ protected function request_body( $initial_body = array() ) {
536
+ $default_body = array(
537
+ 'settings' => array(),
538
+ );
539
+ $body = array_merge( $default_body, $initial_body );
540
+
541
+ // Add interesting fields to the body of each request
542
+ $body[ 'settings' ] = wp_parse_args( $body[ 'settings' ], array(
543
+ 'store_guid' => $this->get_guid(),
544
+ 'base_city' => WC()->countries->get_base_city(),
545
+ 'base_country' => WC()->countries->get_base_country(),
546
+ 'base_state' => WC()->countries->get_base_state(),
547
+ 'base_postcode' => WC()->countries->get_base_postcode(),
548
+ 'currency' => get_woocommerce_currency(),
549
+ 'dimension_unit' => strtolower( get_option( 'woocommerce_dimension_unit' ) ),
550
+ 'weight_unit' => strtolower( get_option( 'woocommerce_weight_unit' ) ),
551
+ 'wcs_version' => WC_Connect_Loader::get_wcs_version(),
552
+ 'jetpack_version' => JETPACK__VERSION,
553
+ 'is_atomic' => WC_Connect_Jetpack::is_atomic_site(),
554
+ 'wc_version' => WC()->version,
555
+ 'wp_version' => get_bloginfo( 'version' ),
556
+ 'last_services_update' => WC_Connect_Options::get_option( 'services_last_update', 0 ),
557
+ 'last_heartbeat' => WC_Connect_Options::get_option( 'last_heartbeat', 0 ),
558
+ 'last_rate_request' => WC_Connect_Options::get_option( 'last_rate_request', 0 ),
559
+ 'active_services' => $this->wc_connect_loader->get_active_services(),
560
+ 'disable_stats' => WC_Connect_Jetpack::is_staging_site(),
561
+ 'taxes_enabled' => wc_tax_enabled() && 'yes' === get_option( 'wc_connect_taxes_enabled' ),
562
+ ) );
563
+
564
+ return $body;
565
+ }
566
+
567
+ /**
568
+ * Generates headers for our request to the WooCommerce Services Server
569
+ *
570
+ * @return array|WP_Error
571
+ */
572
+ protected function request_headers() {
573
+ $authorization = $this->authorization_header();
574
+ if ( is_wp_error( $authorization ) ) {
575
+ return $authorization;
576
+ }
577
+
578
+ $headers = array();
579
+ $locale = strtolower( str_replace( '_', '-', get_locale() ) );
580
+ $locale_elements = explode( '-', $locale );
581
+ $lang = $locale_elements[ 0 ];
582
+ $headers[ 'Accept-Language' ] = $locale . ',' . $lang;
583
+ $headers[ 'Content-Type' ] = 'application/json; charset=utf-8';
584
+ $headers[ 'Accept' ] = 'application/vnd.woocommerce-connect.v1';
585
+ $headers[ 'Authorization' ] = $authorization;
586
+ return $headers;
587
+ }
588
+
589
+ protected function authorization_header() {
590
+ $token = Jetpack_Data::get_access_token( 0 );
591
+ $token = apply_filters( 'wc_connect_jetpack_access_token', $token );
592
+ if ( ! $token || empty( $token->secret ) ) {
593
+ return new WP_Error(
594
+ 'missing_token',
595
+ __( 'Unable to send request to WooCommerce Services server. Jetpack Token is missing', 'woocommerce-services' )
596
+ );
597
+ }
598
+
599
+ if ( false === strpos( $token->secret, '.' ) ) {
600
+ return new WP_Error(
601
+ 'invalid_token',
602
+ __( 'Unable to send request to WooCommerce Services server. Jetpack Token is malformed.', 'woocommerce-services' )
603
+ );
604
+ }
605
+
606
+ list( $token_key, $token_secret ) = explode( '.', $token->secret );
607
+ $token_key = sprintf( '%s:%d:%d', $token_key, JETPACK__API_VERSION, $token->external_user_id );
608
+ $time_diff = (int)Jetpack_Options::get_option( 'time_diff' );
609
+ $timestamp = time() + $time_diff;
610
+ $nonce = wp_generate_password( 10, false );
611
+
612
+ $signature = $this->request_signature( $token_key, $token_secret, $timestamp, $nonce, $time_diff );
613
+ if ( is_wp_error( $signature ) ) {
614
+ return $signature;
615
+ }
616
+
617
+ $auth = array(
618
+ 'token' => $token_key,
619
+ 'timestamp' => $timestamp,
620
+ 'nonce' => $nonce,
621
+ 'signature' => $signature,
622
+ );
623
+
624
+ $header_pieces = array();
625
+ foreach ( $auth as $key => $value ) {
626
+ $header_pieces[] = sprintf( '%s="%s"', $key, $value );
627
+ }
628
+
629
+ $authorization = 'X_JP_Auth ' . join( ' ', $header_pieces );
630
+ return $authorization;
631
+ }
632
+
633
+ protected function request_signature( $token_key, $token_secret, $timestamp, $nonce, $time_diff ) {
634
+ $local_time = $timestamp - $time_diff;
635
+ if ( $local_time < time() - 600 || $local_time > time() + 300 ) {
636
+ return new WP_Error(
637
+ 'invalid_signature',
638
+ __( 'Unable to send request to WooCommerce Services server. The timestamp generated for the signature is too old.', 'woocommerce-services' )
639
+ );
640
+ }
641
+
642
+ $normalized_request_string = join( "\n", array(
643
+ $token_key,
644
+ $timestamp,
645
+ $nonce
646
+ ) ) . "\n";
647
+
648
+ return base64_encode( hash_hmac( 'sha1', $normalized_request_string, $token_secret, true ) );
649
+ }
650
+
651
+ private function get_guid() {
652
+ $guid = WC_Connect_Options::get_option( 'store_guid', false );
653
+ if ( false === $guid ) {
654
+ $guid = $this->generate_guid();
655
+ WC_Connect_Options::update_option( 'store_guid', $guid );
656
+ }
657
+
658
+ return $guid;
659
+ }
660
+
661
+ /**
662
+ * Generates a GUID.
663
+ * This code is based of a snippet found in https://github.com/alixaxel/phunction,
664
+ * which was referenced in http://php.net/manual/en/function.com-create-guid.php
665
+ *
666
+ * @return string
667
+ */
668
+ private function generate_guid() {
669
+ return strtolower( sprintf( '%04X%04X-%04X-%04X-%04X-%04X%04X%04X',
670
+ mt_rand( 0, 65535 ),
671
+ mt_rand( 0, 65535 ),
672
+ mt_rand( 0, 65535 ),
673
+ mt_rand( 16384, 20479 ),
674
+ mt_rand( 32768, 49151 ),
675
+ mt_rand( 0, 65535 ),
676
+ mt_rand( 0, 65535 ),
677
+ mt_rand( 0, 65535 )
678
+ ) );
679
+ }
680
+ }
681
+
682
+ }
trunk/classes/class-wc-connect-compatibility-wc26.php ADDED
@@ -0,0 +1,146 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * A class for working around the quirks and different versions of WordPress/WooCommerce
4
+ * This is for versions 2.6 and lower
5
+ */
6
+
7
+ // No direct access please
8
+ if ( ! defined( 'ABSPATH' ) ) {
9
+ exit;
10
+ }
11
+
12
+ if ( ! class_exists( 'WC_Connect_Compatibility_WC26' ) ) {
13
+
14
+ class WC_Connect_Compatibility_WC26 extends WC_Connect_Compatibility {
15
+ /**
16
+ * Get the ID for a given Order.
17
+ *
18
+ * @param WC_Order $order
19
+ *
20
+ * @return int
21
+ */
22
+ public function get_order_id( WC_Order $order ) {
23
+ return $order->id;
24
+ }
25
+
26
+ /**
27
+ * Get admin url for a given order
28
+ *
29
+ * @param WC_Order $order
30
+ *
31
+ * @return string
32
+ */
33
+ public function get_edit_order_url( WC_Order $order ) {
34
+ return get_admin_url( null, 'post.php?post=' . $this->get_order_id( $order ) . '&action=edit' );
35
+ }
36
+
37
+ /**
38
+ * Get the payment method for a given Order.
39
+ *
40
+ * @param WC_Order $order
41
+ *
42
+ * @return string
43
+ */
44
+ public function get_payment_method( WC_Order $order ) {
45
+ return $order->payment_method;
46
+ }
47
+
48
+ /**
49
+ * Retrieve the corresponding Product for the given Order Item.
50
+ *
51
+ * @param WC_Order $order
52
+ * @param WC_Order_Item|WC_Order_Item_Product|array $item
53
+ *
54
+ * @return WC_Product
55
+ */
56
+ public function get_item_product( WC_Order $order, $item ) {
57
+ return $order->get_product_from_item( $item );
58
+ }
59
+
60
+ /**
61
+ * Get formatted list of Product Variations, if applicable.
62
+ *
63
+ * @param WC_Product_Variation $product
64
+ * @param bool $flat
65
+ *
66
+ * @return string
67
+ */
68
+ public function get_formatted_variation( WC_Product_Variation $product, $flat = false ) {
69
+ return $product->get_formatted_variation_attributes( $flat );
70
+ }
71
+
72
+ /**
73
+ * Get the most specific ID for a given Product.
74
+ *
75
+ * Note: Returns the Variation ID for Variable Products.
76
+ *
77
+ * @param WC_Product $product
78
+ *
79
+ * @return int
80
+ */
81
+ public function get_product_id( WC_Product $product ) {
82
+ return ( $product->is_type( 'variation' ) ) ? $product->variation_id : $product->get_id();
83
+ }
84
+
85
+ /**
86
+ * Get the top-level ID for a given Product.
87
+ *
88
+ * Note: Returns the Parent ID for Variable Products.
89
+ *
90
+ * @param WC_Product $product
91
+ *
92
+ * @return int
93
+ */
94
+ public function get_parent_product_id( WC_Product $product ) {
95
+ return ( $product->is_type( 'variation' ) ) ? $product->parent->get_id() : $product->get_id();
96
+ }
97
+
98
+ /**
99
+ * For a given product ID, it tries to find its name inside an order's line items.
100
+ * This is useful when an order has a product which was later deleted from the
101
+ * store.
102
+ *
103
+ * @param int $product_id Product ID or variation ID
104
+ * @param WC_Order $order
105
+ * @return string The product (or variation) name, ready to print
106
+ */
107
+ public function get_product_name_from_order( $product_id, $order ) {
108
+ foreach ( $order->get_items() as $line_item ) {
109
+ if ( (int) $line_item[ 'product_id' ] === $product_id || (int) $line_item[ 'variation_id' ] === $product_id ) {
110
+ /* translators: %1$d: Product ID, %2$s: Product Name */
111
+ return sprintf( __( '#%1$d - %2$s', 'woocommerce-services' ), $product_id, $line_item[ 'name' ] );
112
+ }
113
+ }
114
+
115
+ /* translators: %d: Deleted Product ID */
116
+ return sprintf( __( '#%d - [Deleted product]', 'woocommerce-services' ), $product_id );
117
+ }
118
+
119
+ /**
120
+ * For a given product ID, it tries to find its price inside an order's line items.
121
+ *
122
+ * @param int $product_id Product ID or variation ID
123
+ * @param WC_Order $order
124
+ * @return float The product (or variation) price, or NULL if it wasn't found
125
+ */
126
+ public function get_product_price_from_order( $product_id, $order ) {
127
+ foreach ( $order->get_items() as $line_item ) {
128
+ if ( (int) $line_item[ 'product_id' ] === $product_id || (int) $line_item[ 'variation_id' ] === $product_id ) {
129
+ return round( floatval( $line_item[ 'total' ] ) / $line_item[ 'qty' ], 2 );
130
+ }
131
+ }
132
+ return null;
133
+ }
134
+
135
+ /**
136
+ * For a given product, return it's name. In supported versions, variable
137
+ * products will include their attributes.
138
+ *
139
+ * @param WC_Product $product Product (variable, simple, etc)
140
+ * @return string The product (or variation) name, ready to print
141
+ */
142
+ public function get_product_name( WC_Product $product ) {
143
+ return $product->get_title();
144
+ }
145
+ }
146
+ }
trunk/classes/class-wc-connect-compatibility-wc30.php ADDED
@@ -0,0 +1,172 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * A class for working around the quirks and different versions of WordPress/WooCommerce
4
+ * This is for versions higher than 2.6 (3.0 and higher)
5
+ */
6
+
7
+ // No direct access please
8
+ if ( ! defined( 'ABSPATH' ) ) {
9
+ exit;
10
+ }
11
+
12
+ if ( ! class_exists( 'WC_Connect_Compatibility_WC30' ) ) {
13
+
14
+ class WC_Connect_Compatibility_WC30 extends WC_Connect_Compatibility {
15
+ /**
16
+ * Get the ID for a given Order.
17
+ *
18
+ * @param WC_Order $order
19
+ *
20
+ * @return int
21
+ */
22
+ public function get_order_id( WC_Order $order ) {
23
+ return $order->get_id();
24
+ }
25
+
26
+ /**
27
+ * Get admin url for a given order
28
+ *
29
+ * @param WC_Order $order
30
+ *
31
+ * @return string
32
+ */
33
+ public function get_edit_order_url( WC_Order $order ) {
34
+ return $order->get_edit_order_url();
35
+ }
36
+
37
+ /**
38
+ * Get the payment method for a given Order.
39
+ *
40
+ * @param WC_Order $order
41
+ *
42
+ * @return string
43
+ */
44
+ public function get_payment_method( WC_Order $order ) {
45
+ return $order->get_payment_method();
46
+ }
47
+
48
+ /**
49
+ * Retrieve the corresponding Product for the given Order Item.
50
+ *
51
+ * @param WC_Order $order
52
+ * @param WC_Order_Item|WC_Order_Item_Product|array $item
53
+ *
54
+ * @return WC_Product
55
+ */
56
+ public function get_item_product( WC_Order $order, $item ) {
57
+ if ( is_array( $item ) ) {
58
+ return wc_get_product( $item[ 'product_id' ] );
59
+ }
60
+ return $item->get_product();
61
+ }
62
+
63
+ /**
64
+ * Get formatted list of Product Variations, if applicable.
65
+ *
66
+ * @param WC_Product_Variation $product
67
+ * @param bool $flat
68
+ *
69
+ * @return string
70
+ */
71
+ public function get_formatted_variation( WC_Product_Variation $product, $flat = false ) {
72
+ return wc_get_formatted_variation( $product, $flat );
73
+ }
74
+
75
+ /**
76
+ * Get the most specific ID for a given Product.
77
+ *
78
+ * Note: Returns the Variation ID for Variable Products.
79
+ *
80
+ * @param WC_Product $product
81
+ *
82
+ * @return int
83
+ */
84
+ public function get_product_id( WC_Product $product ) {
85
+ return $product->get_id();
86
+ }
87
+
88
+ /**
89
+ * Get the top-level ID for a given Product.
90
+ *
91
+ * Note: Returns the Parent ID for Variable Products.
92
+ *
93
+ * @param WC_Product $product
94
+ *
95
+ * @return int
96
+ */
97
+ public function get_parent_product_id( WC_Product $product ) {
98
+ return ( $product->is_type( 'variation' ) ) ? $product->get_parent_id() : $product->get_id();
99
+ }
100
+
101
+ /**
102
+ * For a given product ID, it tries to find its name inside an order's line items.
103
+ * This is useful when an order has a product which was later deleted from the
104
+ * store.
105
+ *
106
+ * @param int $product_id Product ID or variation ID
107
+ * @param WC_Order $order
108
+ * @return string The product (or variation) name, ready to print
109
+ */
110
+ public function get_product_name_from_order( $product_id, $order ) {
111
+ foreach ( $order->get_items() as $line_item ) {
112
+ $line_product_id = $line_item->get_product_id();
113
+ $line_variation_id = $line_item->get_variation_id();
114
+
115
+ if ( ! $line_product_id ) {
116
+ $line_product_id = (int) get_metadata( 'order_item', $line_item->get_id(), '_product_id', true );
117
+ }
118
+
119
+ if ( ! $line_variation_id ) {
120
+ $line_variation_id = (int) get_metadata( 'order_item', $line_item->get_id(), '_variation_id', true );
121
+ }
122
+
123
+ if ( $line_product_id === $product_id || $line_variation_id === $product_id ) {
124
+ /* translators: %1$d: Product ID, %2$s: Product Name */
125
+ return sprintf( __( '#%1$d - %2$s', 'woocommerce-services' ), $product_id, $line_item->get_name() );
126
+ }
127
+ }
128
+
129
+ /* translators: %d: Deleted Product ID */
130
+ return sprintf( __( '#%d - [Deleted product]', 'woocommerce-services' ), $product_id );
131
+ }
132
+
133
+ /**
134
+ * For a given product ID, it tries to find its price inside an order's line items.
135
+ *
136
+ * @param int $product_id Product ID or variation ID
137
+ * @param WC_Order $order
138
+ * @return float The product (or variation) price, or NULL if it wasn't found
139
+ */
140
+ public function get_product_price_from_order( $product_id, $order ) {
141
+ foreach ( $order->get_items() as $line_item ) {
142
+ $line_product_id = $line_item->get_product_id();
143
+ $line_variation_id = $line_item->get_variation_id();
144
+
145
+ if ( ! $line_product_id ) {
146
+ $line_product_id = (int) get_metadata( 'order_item', $line_item->get_id(), '_product_id', true );
147
+ }
148
+
149
+ if ( ! $line_variation_id ) {
150
+ $line_variation_id = (int) get_metadata( 'order_item', $line_item->get_id(), '_variation_id', true );
151
+ }
152
+
153
+ if ( $line_product_id === $product_id || $line_variation_id === $product_id ) {
154
+ return round( floatval( $line_item->get_total() ) / $line_item->get_quantity(), 2 );
155
+ }
156
+ }
157
+ return null;
158
+ }
159
+
160
+ /**
161
+ * For a given product, return it's name. In supported versions, variable
162
+ * products will include their attributes.
163
+ *
164
+ * @param WC_Product $product Product (variable, simple, etc)
165
+ * @return string The product (or variation) name, ready to print
166
+ */
167
+ public function get_product_name( WC_Product $product ) {
168
+ return $product->get_name();
169
+ }
170
+ }
171
+
172
+ }
trunk/classes/class-wc-connect-compatibility.php ADDED
@@ -0,0 +1,151 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * A class for working around the quirks and different versions of WordPress/WooCommerce
4
+ * This is the base class. Its static members auto-select the correct version to use.
5
+ */
6
+
7
+ // No direct access please
8
+ if ( ! defined( 'ABSPATH' ) ) {
9
+ exit;
10
+ }
11
+
12
+ if ( ! class_exists( 'WC_Connect_Compatibility' ) ) {
13
+
14
+ abstract class WC_Connect_Compatibility {
15
+ private static $singleton;
16
+ private static $version = WC_VERSION;
17
+
18
+ /**
19
+ * @return WC_Connect_Compatibility
20
+ */
21
+ public static function instance() {
22
+ if ( is_null( self::$singleton ) ) {
23
+ self::$singleton = self::select_compatibility();
24
+ }
25
+
26
+ return self::$singleton;
27
+ }
28
+
29
+ /**
30
+ * @return WC_Connect_Compatibility subclass for active version of WooCommerce
31
+ */
32
+ private static function select_compatibility() {
33
+ if ( version_compare( self::$version, '3.0.0', '<' ) ) {
34
+ require_once 'class-wc-connect-compatibility-wc26.php';
35
+ return new WC_Connect_Compatibility_WC26();
36
+ } else {
37
+ require_once 'class-wc-connect-compatibility-wc30.php';
38
+ return new WC_Connect_Compatibility_WC30();
39
+ }
40
+ }
41
+
42
+ public static function set_version( $value ) {
43
+ self::$singleton = null;
44
+ self::$version = $value;
45
+ }
46
+
47
+ public static function reset_version() {
48
+ self::$singleton = null;
49
+ self::$version = WC_VERSION;
50
+ }
51
+
52
+ /**
53
+ * Get the ID for a given Order.
54
+ *
55
+ * @param WC_Order $order
56
+ *
57
+ * @return int
58
+ */
59
+ abstract public function get_order_id( WC_Order $order );
60
+
61
+ /**
62
+ * Get admin url for a given order
63
+ *
64
+ * @param WC_Order $order
65
+ *
66
+ * @return string
67
+ */
68
+ abstract public function get_edit_order_url( WC_Order $order );
69
+
70
+ /**
71
+ * Get the payment method for a given Order.
72
+ *
73
+ * @param WC_Order $order
74
+ *
75
+ * @return string
76
+ */
77
+ abstract public function get_payment_method( WC_Order $order );
78
+
79
+ /**
80
+ * Retrieve the corresponding Product for the given Order Item.
81
+ *
82
+ * @param WC_Order $order
83
+ * @param WC_Order_Item|WC_Order_Item_Product|array $item
84
+ *
85
+ * @return WC_Product
86
+ */
87
+ abstract public function get_item_product( WC_Order $order, $item );
88
+
89
+ /**
90
+ * Get formatted list of Product Variations, if applicable.
91
+ *
92
+ * @param WC_Product_Variation $product
93
+ * @param bool $flat
94
+ *
95
+ * @return string
96
+ */
97
+ abstract public function get_formatted_variation( WC_Product_Variation $product, $flat = false );
98
+
99
+ /**
100
+ * Get the most specific ID for a given Product.
101
+ *
102
+ * Note: Returns the Variation ID for Variable Products.
103
+ *
104
+ * @param WC_Product $product
105
+ *
106
+ * @return int
107
+ */
108
+ abstract public function get_product_id( WC_Product $product );
109
+
110
+ /**
111
+ * Get the top-level ID for a given Product.
112
+ *
113
+ * Note: Returns the Parent ID for Variable Products.
114
+ *
115
+ * @param WC_Product $product
116
+ *
117
+ * @return int
118
+ */
119
+ abstract public function get_parent_product_id( WC_Product $product );
120
+
121
+ /**
122
+ * For a given product ID, it tries to find its name inside an order's line items.
123
+ * This is useful when an order has a product which was later deleted from the
124
+ * store.
125
+ *
126
+ * @param int $product_id Product ID or variation ID
127
+ * @param WC_Order $order
128
+ * @return string The product (or variation) name, ready to print
129
+ */
130
+ abstract public function get_product_name_from_order( $product_id, $order );
131
+
132
+ /**
133
+ * For a given product ID, it tries to find its price inside an order's line items.
134
+ *
135
+ * @param int $product_id Product ID or variation ID
136
+ * @param WC_Order $order
137
+ * @return float The product (or variation) price, or NULL if it wasn't found
138
+ */
139
+ abstract public function get_product_price_from_order( $product_id, $order );
140
+
141
+ /**
142
+ * For a given product, return it's name. In supported versions, variable
143
+ * products will include their attributes.
144
+ *
145
+ * @param WC_Product $product Product (variable, simple, etc)
146
+ * @return string The product (or variation) name, ready to print
147
+ */
148
+ abstract public function get_product_name( WC_Product $product );
149
+ }
150
+
151
+ }
trunk/classes/class-wc-connect-debug-tools.php ADDED
@@ -0,0 +1,38 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // No direct access please
4
+ if ( ! defined( 'ABSPATH' ) ) {
5
+ exit;
6
+ }
7
+
8
+ if ( ! class_exists( 'WC_Connect_Debug_Tools' ) ) {
9
+
10
+ class WC_Connect_Debug_Tools {
11
+
12
+ function __construct( WC_Connect_API_Client $api_client ) {
13
+ $this->api_client = $api_client;
14
+
15
+ add_filter( 'woocommerce_debug_tools', array( $this, 'woocommerce_debug_tools' ) );
16
+ }
17
+
18
+ function woocommerce_debug_tools( $tools ) {
19
+ $tools['test_wcc_connection'] = array(
20
+ 'name' => __( 'Test your WooCommerce Services connection', 'woocommerce-services' ),
21
+ 'button' => __( 'Test Connection', 'woocommerce-services' ),
22
+ 'desc' => __( 'This will test your WooCommerce Services connection to ensure everything is working correctly', 'woocommerce-services' ),
23
+ 'callback' => array( $this, 'test_connection' ),
24
+ );
25
+ return $tools;
26
+ }
27
+
28
+ function test_connection() {
29
+ $test_request = $this->api_client->auth_test();
30
+ if ( $test_request && ! is_wp_error( $test_request ) && $test_request->authorized ) {
31
+ echo '<div class="updated inline"><p>' . __( 'Your site is succesfully communicating to the WooCommerce Services API.', 'woocommerce-services' ) . '</p></div>';
32
+ } else {
33
+ echo '<div class="error inline"><p>' . __( 'ERROR: Your site has a problem connecting to the WooCommerce Services API. Please make sure your Jetpack connection is working.', 'woocommerce-services' ) . '</p></div>';
34
+ }
35
+ }
36
+
37
+ }
38
+ }
trunk/classes/class-wc-connect-error-notice.php ADDED
@@ -0,0 +1,111 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Show admin notices when errors occur
5
+ */
6
+
7
+ // No direct access please
8
+ if ( ! defined( 'ABSPATH' ) ) {
9
+ exit;
10
+ }
11
+
12
+ if ( ! class_exists( 'WC_Connect_Error_Notice' ) ) {
13
+
14
+ class WC_Connect_Error_Notice {
15
+
16
+ private static $inst = null;
17
+
18
+ public static function instance() {
19
+ if ( null === self::$inst ) {
20
+ self::$inst = new WC_Connect_Error_Notice();
21
+ }
22
+
23
+ return self::$inst;
24
+ }
25
+
26
+ public function enable_notice( $error = true ) {
27
+ WC_Connect_Options::update_option( 'error_notice', $error );
28
+ }
29
+
30
+ public function disable_notice() {
31
+ WC_Connect_Options::update_option( 'error_notice', false );
32
+ }
33
+
34
+ public function render_notice() {
35
+ $error_notice = filter_input( INPUT_GET, 'wc-connect-error-notice' );
36
+ if ( 'disable' === $error_notice ) {
37
+ WC_Connect_Options::update_option( 'error_notice', false );
38
+ $url = remove_query_arg( 'wc-connect-error-notice' );
39
+ wp_safe_redirect( $url );
40
+ exit;
41
+ }
42
+
43
+ if ( $this->notice_enabled() ) {
44
+ $this->show_notice();
45
+ }
46
+ }
47
+
48
+ private function notice_enabled() {
49
+ return WC_Connect_Options::get_option( 'error_notice', false );
50
+ }
51
+
52
+ private function show_notice() {
53
+ $link_status = admin_url( 'admin.php?page=wc-status&tab=connect' );
54
+ $link_dismiss = add_query_arg( array( 'wc-connect-error-notice' => 'disable' ) );
55
+ $error = $this->notice_enabled();
56
+
57
+ if ( ! is_wp_error( $error ) ) {
58
+ return;
59
+ }
60
+
61
+ $message = false;
62
+
63
+ if (
64
+ 'product_missing_weight' === $error->get_error_code() ||
65
+ 'product_missing_dimension' === $error->get_error_code()
66
+ ) {
67
+ $error_data = $error->get_error_data();
68
+ $id = $error_data['product_id'];
69
+ $product = wc_get_product( $id );
70
+
71
+ if (
72
+ ! $product ||
73
+ (
74
+ $product->has_weight() &&
75
+ $product->get_length() &&
76
+ $product->get_height() &&
77
+ $product->get_width()
78
+ )
79
+ ) {
80
+ $this->disable_notice();
81
+ return;
82
+ }
83
+
84
+ $product_name = WC_Connect_Compatibility::instance()->get_product_name( $product );
85
+ $product_id = is_a( $product, 'WC_Product_Variation' ) ? $product->get_parent_id() : $id;
86
+ $message = sprintf(
87
+ __( '<strong>"%2$s" is missing weight, length, width, or height.</strong><br />Shipping rates cannot be calculated. <a href="%1$s">Enter dimensions and weight for %2$s</a> so your customers can purchase this item.', 'woocommerce-services' ),
88
+ get_edit_post_link( $product_id ), $product_name
89
+ );
90
+ }
91
+
92
+ if ( ! $message ) {
93
+ return;
94
+ }
95
+
96
+ $allowed_html = array(
97
+ 'a' => array( 'href' => array() ),
98
+ 'strong' => array(),
99
+ 'br' => array(),
100
+ );
101
+ ?>
102
+ <div class='notice notice-error' style="position: relative;">
103
+ <a href="<?php echo esc_url( $link_dismiss ); ?>" style="text-decoration: none;" class="notice-dismiss" title="<?php esc_attr_e( 'Dismiss this notice', 'woocommerce-services' ); ?>"></a>
104
+ <p><?php echo wp_kses( $message, $allowed_html ); ?></p>
105
+ </div>
106
+ <?php
107
+ echo "";
108
+ }
109
+ }
110
+
111
+ }
trunk/classes/class-wc-connect-extension-compatibility.php ADDED
@@ -0,0 +1,41 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Extension_Compatibility' ) ) {
4
+ class WC_Connect_Extension_Compatibility {
5
+ /**
6
+ * Function called when a new tracking number is added to the order
7
+ *
8
+ * @param $order_id - order ID
9
+ * @param $carrier_id - carrier ID, as returned on the label objects returned by the server
10
+ * @param $tracking_number - tracking number string
11
+ */
12
+ public static function on_new_tracking_number( $order_id, $carrier_id, $tracking_number ) {
13
+ //call WooCommerce Shipment Tracking if it's installed
14
+ if ( function_exists( 'wc_st_add_tracking_number' ) ) {
15
+ //note: the only carrier ID we use at the moment is 'usps', which is the same in WC_ST, but this might require a mapping
16
+ wc_st_add_tracking_number( $order_id, $tracking_number, $carrier_id );
17
+ }
18
+ }
19
+
20
+ /**
21
+ * Checks if WooCommerce Services should email the tracking details, or if another extension is taking care of that already
22
+ *
23
+ * @param $order_id - order ID
24
+ * @return boolean true if WCS should send the tracking info, false otherwise
25
+ */
26
+ public static function should_email_tracking_details( $order_id ) {
27
+ if ( function_exists( 'wc_shipment_tracking' ) ) {
28
+ $shipment_tracking = wc_shipment_tracking();
29
+ if ( property_exists( $shipment_tracking, 'actions' )
30
+ && method_exists( $shipment_tracking->actions, 'get_tracking_items' ) ) {
31
+ $shipment_tracking_items = $shipment_tracking->actions->get_tracking_items( $order_id );
32
+ if ( ! empty( $shipment_tracking_items ) ) {
33
+ return false;
34
+ }
35
+ }
36
+ }
37
+
38
+ return true;
39
+ }
40
+ }
41
+ }
trunk/classes/class-wc-connect-functions.php ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Functions' ) ) {
4
+ class WC_Connect_Functions {
5
+ /**
6
+ * Checks if the potentially expensive Shipping/Tax API requests should be sent
7
+ * based on the context in which they are initialized
8
+ * @return bool true if the request can be sent, false otherwise
9
+ */
10
+ public static function should_send_cart_api_request() {
11
+ return ! (
12
+ // Skip for carts loaded from session in the dashboard
13
+ ( is_admin() && did_action( 'woocommerce_cart_loaded_from_session' ) ) ||
14
+ // Skip during Jetpack API requests
15
+ ( false !== strpos( $_SERVER['REQUEST_URI'], 'jetpack/v4/' ) ) ||
16
+ // Skip during REST API or XMLRPC requests
17
+ ( defined( 'REST_REQUEST' ) || defined( 'REST_API_REQUEST' ) || defined( 'XMLRPC_REQUEST' ) ) ||
18
+ // Skip during Jetpack REST API proxy requests
19
+ ( isset( $_GET['rest_route'] ) && isset( $_GET['_for'] ) && ( 'jetpack' === $_GET['_for'] ) )
20
+ );
21
+ }
22
+ }
23
+ }
trunk/classes/class-wc-connect-help-view.php ADDED
@@ -0,0 +1,345 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Help_View' ) ) {
4
+
5
+ class WC_Connect_Help_View {
6
+
7
+ /**
8
+ * @var WC_Connect_Service_Schemas_Store
9
+ */
10
+ protected $service_schemas_store;
11
+
12
+ /**
13
+ * @var WC_Connect_Service_Settings_Store
14
+ */
15
+ protected $service_settings_store;
16
+
17
+ /**
18
+ * @var WC_Connect_Logger
19
+ */
20
+ protected $logger;
21
+
22
+ /**
23
+ * @array
24
+ */
25
+ protected $fieldsets;
26
+
27
+ public function __construct( WC_Connect_Service_Schemas_Store $service_schemas_store,
28
+ WC_Connect_Service_Settings_Store $service_settings_store,
29
+ WC_Connect_Logger $logger ) {
30
+
31
+ $this->service_schemas_store = $service_schemas_store;
32
+ $this->service_settings_store = $service_settings_store;
33
+ $this->logger = $logger;
34
+
35
+ add_filter( 'woocommerce_admin_status_tabs', array( $this, 'status_tabs' ) );
36
+ add_action( 'woocommerce_admin_status_content_connect', array( $this, 'page' ) );
37
+ }
38
+
39
+ protected function get_health_items() {
40
+ $health_items = array();
41
+
42
+ // WooCommerce
43
+ // Only one of the following should present
44
+ // Check that WooCommerce is at least 2.6 or higher (feature-plugin only)
45
+ // Check that WooCommerce base_country is set
46
+ $base_country = WC()->countries->get_base_country();
47
+ if ( version_compare( WC()->version, WOOCOMMERCE_CONNECT_MINIMUM_WOOCOMMERCE_VERSION, "<" ) ) {
48
+ $health_item = array(
49
+ 'state' => 'error',
50
+ 'message' => sprintf(
51
+ __( 'WooCommerce %s or higher is required (You are running %s)', 'woocommerce-services' ),
52
+ WOOCOMMERCE_CONNECT_MINIMUM_WOOCOMMERCE_VERSION,
53
+ WC()->version
54
+ ),
55
+ );
56
+ } else if ( empty( $base_country ) ) {
57
+ $health_item = array(
58
+ 'state' => 'error',
59
+ 'message' => __( 'Please set Base Location in WooCommerce Settings > General', 'woocommerce-services' ),
60
+ );
61
+ } else {
62
+ $health_item = array(
63
+ 'state' => 'success',
64
+ 'message' => sprintf(
65
+ __( 'WooCommerce %s is configured correctly', 'woocommerce-services' ),
66
+ WC()->version
67
+ ),
68
+ );
69
+ }
70
+ $health_items['woocommerce'] = $health_item;
71
+
72
+ // Jetpack
73
+ // Only one of the following should present
74
+ // Check that Jetpack is active
75
+ // Check that Jetpack is connected
76
+ include_once ( ABSPATH . 'wp-admin/includes/plugin.php' ); // required for is_plugin_active
77
+ $is_connected = WC_Connect_Jetpack::is_active() || WC_Connect_Jetpack::is_development_mode();
78
+ if ( ! is_plugin_active( 'jetpack/jetpack.php' ) ) {
79
+ $health_item = array(
80
+ 'state' => 'error',
81
+ 'message' => sprintf(
82
+ __( 'Please install and activate the Jetpack plugin, version %s or higher', 'woocommerce-services' ),
83
+ WOOCOMMERCE_CONNECT_MINIMUM_JETPACK_VERSION
84
+ ),
85
+ );
86
+ } else if ( version_compare( JETPACK__VERSION, WOOCOMMERCE_CONNECT_MINIMUM_JETPACK_VERSION, "<" ) ) {
87
+ $health_item = array(
88
+ 'state' => 'error',
89
+ 'message' => sprintf(
90
+ __( 'Jetpack %s or higher is required (You are running %s)', 'woocommerce-services' ),
91
+ WOOCOMMERCE_CONNECT_MINIMUM_JETPACK_VERSION,
92
+ JETPACK__VERSION
93
+ ),
94
+ );
95
+ } else if ( ! $is_connected ) {
96
+ $health_item = array(
97
+ 'state' => 'error',
98
+ 'message' => __( 'Jetpack is not connected to WordPress.com. Make sure the Jetpack plugin is installed, activated, and connected.', 'woocommerce-services' ),
99
+ );
100
+ } else if ( WC_Connect_Jetpack::is_staging_site() ) {
101
+ $health_item = array(
102
+ 'state' => 'warning',
103
+ 'message' => __( 'This is a Jetpack staging site', 'woocommerce-services' ),
104
+ );
105
+ } else {
106
+ $health_item = array(
107
+ 'state' => 'success',
108
+ 'message' => sprintf(
109
+ __( 'Jetpack %s is connected and working correctly', 'woocommerce-services' ),
110
+ JETPACK__VERSION
111
+ ),
112
+ );
113
+ }
114
+ $health_items['jetpack'] = $health_item;
115
+
116
+ // Lastly, do the WooCommerce Services health check
117
+ // Check that we have schema
118
+ // Check that we are able to talk to the WooCommerce Services server
119
+ $schemas = $this->service_schemas_store->get_service_schemas();
120
+ $last_fetch_timestamp = $this->service_schemas_store->get_last_fetch_timestamp();
121
+ if ( isset( $_GET['refresh'] ) && 'failed' === $_GET['refresh'] ) {
122
+ $health_item = array(
123
+ 'state' => 'error',
124
+ 'message' => __( 'An error occurred while refreshing service data.', 'woocommerce-services' ),
125
+ 'timestamp' => $last_fetch_timestamp,
126
+ );
127
+ } else if ( is_null( $schemas ) ) {
128
+ $health_item = array(
129
+ 'state' => 'error',
130
+ 'message' => __( 'No service data available', 'woocommerce-services' ),
131
+ );
132
+ } else if ( is_null( $last_fetch_timestamp ) ) {
133
+ $health_item = array(
134
+ 'state' => 'warning',
135
+ 'message' => __( 'Service data was found, but may be out of date', 'woocommerce-services' ),
136
+ 'timestamp' => $last_fetch_timestamp
137
+ );
138
+ } else if ( $last_fetch_timestamp < time() - WOOCOMMERCE_CONNECT_SCHEMA_AGE_ERROR_THRESHOLD ) {
139
+ $health_item = array(
140
+ 'state' => 'error',
141
+ 'message' => __( 'Service data was found, but is more than three days old', 'woocommerce-services' ),
142
+ 'timestamp' => $last_fetch_timestamp
143
+ );
144
+ } else if ( $last_fetch_timestamp < time() - WOOCOMMERCE_CONNECT_SCHEMA_AGE_WARNING_THRESHOLD ) {
145
+ $health_item = array(
146
+ 'state' => 'warning',
147
+ 'message' => __( 'Service data was found, but is more than one day old', 'woocommerce-services' ),
148
+ 'timestamp' => $last_fetch_timestamp
149
+ );
150
+ } else {
151
+ $health_item = array(
152
+ 'state' => 'success',
153
+ 'message' => __( 'Service data is up-to-date', 'woocommerce-services' ),
154
+ 'timestamp' => $last_fetch_timestamp
155
+ );
156
+ }
157
+
158
+ $health_items['woocommerce_services'] = $health_item;
159
+
160
+ return $health_items;
161
+ }
162
+
163
+ protected function get_services_items() {
164
+ $available_service_method_ids = $this->service_schemas_store->get_all_shipping_method_ids();
165
+ if ( empty( $available_service_method_ids ) ) {
166
+ return false;
167
+ }
168
+
169
+ $service_items = array();
170
+
171
+ $enabled_services = $this->service_settings_store->get_enabled_services();
172
+
173
+ foreach ( (array) $enabled_services as $enabled_service ) {
174
+ $last_failed_request_timestamp = intval( WC_Connect_Options::get_shipping_method_option( 'failure_timestamp', -1, $enabled_service->method_id, $enabled_service->instance_id ) );
175
+
176
+ $service_settings_url = esc_url( add_query_arg(
177
+ array(
178
+ 'page' => 'wc-settings',
179
+ 'tab' => 'shipping',
180
+ 'instance_id' => $enabled_service->instance_id
181
+ ),
182
+ admin_url( 'admin.php' )
183
+ ) );
184
+
185
+ // Figure out if the service has any settings saved at all
186
+ $service_settings = $this->service_settings_store->get_service_settings( $enabled_service->method_id, $enabled_service->instance_id );
187
+ if ( empty( $service_settings ) ) {
188
+ $state = 'error';
189
+ $message = __( 'Setup for this service has not yet been completed', 'woocommerce-services' );
190
+ } else if ( -1 === $last_failed_request_timestamp ) {
191
+ $state = 'warning';
192
+ $message = __( 'No rate requests have yet been made for this service', 'woocommerce-services' );
193
+ } else if ( 0 === $last_failed_request_timestamp ) {
194
+ $state = 'success';
195
+ $message = __( 'The most recent rate request was successful', 'woocommerce-services' );
196
+ } else {
197
+ $state = 'error';
198
+ $message = __( 'The most recent rate request failed', 'woocommerce-services' );
199
+ }
200
+
201
+ $subtitle = sprintf(
202
+ __( '%s Shipping Zone', 'woocommerce-services' ),
203
+ $enabled_service->zone_name
204
+ );
205
+
206
+ $service_items[] = (object) array(
207
+ 'title' => $enabled_service->title,
208
+ 'subtitle' => $subtitle,
209
+ 'state' => $state,
210
+ 'message' => $message,
211
+ 'timestamp' => $last_failed_request_timestamp,
212
+ 'url' => $service_settings_url,
213
+ );
214
+ }
215
+
216
+ return $service_items;
217
+ }
218
+
219
+ /**
220
+ * Gets the last 10 lines from the WooCommerce Services log by feature, if it exists
221
+ */
222
+ protected function get_debug_log_data( $feature = '' ) {
223
+ $data = new stdClass;
224
+ $data->key = '';
225
+ $data->file = null;
226
+ $data->tail = array();
227
+
228
+ if ( ! method_exists( 'WC_Admin_Status', 'scan_log_files' ) ) {
229
+ return $data;
230
+ }
231
+
232
+ $log_prefix = 'wc\-services';
233
+
234
+ if ( ! empty( $feature ) ) {
235
+ $log_prefix .= '\-' . $feature;
236
+ }
237
+
238
+ $logs = WC_Admin_Status::scan_log_files();
239
+ $latest_file_date = 0;
240
+
241
+ foreach ( $logs as $log_key => $log_file ) {
242
+ if ( ! preg_match( '/' . $log_prefix . '\-(?:\d{4}\-\d{2}\-\d{2}\-)?[0-9a-f]{32}\-log/', $log_key ) ) {
243
+ continue;
244
+ }
245
+
246
+ $log_file_path = WC_LOG_DIR . $log_file;
247
+ $file_date = filemtime( $log_file_path );
248
+
249
+ if ( $latest_file_date < $file_date ) {
250
+ $latest_file_date = $file_date;
251
+ $data->file = $log_file_path;
252
+ $data->key = $log_key;
253
+ }
254
+ }
255
+
256
+ if ( null !== $data->file ) {
257
+ $complete_log = file( $data->file );
258
+ $data->tail = array_slice( $complete_log, -10 );
259
+ }
260
+
261
+ $line_count = count( $data->tail );
262
+ if ( $line_count < 1 ) {
263
+ $log_tail = array( __( 'Log is empty', 'woocommerce-services' ) );
264
+ } else {
265
+ $log_tail = $data->tail;
266
+ }
267
+
268
+ return array(
269
+ 'tail' => implode( $log_tail ),
270
+ 'url' => $url = add_query_arg(
271
+ array(
272
+ 'page' => 'wc-status',
273
+ 'tab' => 'logs',
274
+ 'log_file' => $data->key
275
+ ),
276
+ admin_url( 'admin.php' )
277
+ ),
278
+ 'count' => $line_count,
279
+ );
280
+ }
281
+
282
+ /**
283
+ * Filters the WooCommerce System Status Tabs to add connect
284
+ *
285
+ * @param array $tabs
286
+ * @return array
287
+ */
288
+ public function status_tabs( $tabs ) {
289
+ if ( ! is_array( $tabs ) ) {
290
+ $tabs = array();
291
+ }
292
+ $tabs[ 'connect' ] = _x( 'WooCommerce Services', 'The WooCommerce Services brandname', 'woocommerce-services' );
293
+ return $tabs;
294
+ }
295
+
296
+ /**
297
+ * Returns the data bootstrap for the help page
298
+ *
299
+ * @return array
300
+ */
301
+ protected function get_form_data() {
302
+ $form_data = array(
303
+ 'health_items' => $this->get_health_items(),
304
+ 'services' => $this->get_services_items(),
305
+ 'logging_enabled' => $this->logger->is_logging_enabled(),
306
+ 'debug_enabled' => $this->logger->is_debug_enabled(),
307
+ 'logs' => array(
308
+ 'shipping' => $this->get_debug_log_data( 'shipping' ),
309
+ 'taxes' => $this->get_debug_log_data( 'taxes' ),
310
+ 'other' => $this->get_debug_log_data(),
311
+ )
312
+ );
313
+
314
+ return $form_data;
315
+ }
316
+
317
+ /**
318
+ * Localizes the bootstrap, enqueues the script and styles for the help page
319
+ */
320
+ public function page() {
321
+ if ( isset( $_GET['refresh'] ) && 'true' === $_GET['refresh'] ) {
322
+ $fetched = $this->service_schemas_store->fetch_service_schemas_from_connect_server();
323
+ $url = add_query_arg( 'refresh', $fetched ? false : 'failed' );
324
+ wp_safe_redirect( $url );
325
+ }
326
+
327
+ ?>
328
+ <h2>
329
+ <?php _e( 'WooCommerce Services Status', 'woocommerce-services' ); ?>
330
+ </h2>
331
+ <?php
332
+
333
+ do_action( 'enqueue_wc_connect_script', 'wc-connect-admin-status', array(
334
+ 'formData' => $this->get_form_data(),
335
+ ) );
336
+
337
+ do_action( 'enqueue_wc_connect_script', 'wc-connect-admin-test-print', array(
338
+ 'storeOptions' => $this->service_settings_store->get_store_options(),
339
+ 'paperSize' => $this->service_settings_store->get_preferred_paper_size(),
340
+ ) );
341
+ }
342
+
343
+ }
344
+
345
+ }
trunk/classes/class-wc-connect-jetpack.php ADDED
@@ -0,0 +1,112 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Jetpack' ) ) {
4
+ class WC_Connect_Jetpack {
5
+ /**
6
+ * Helper method to get if Jetpack is in development mode
7
+ * @return bool
8
+ */
9
+ public static function is_development_mode() {
10
+ if ( method_exists( 'Jetpack', 'is_development_mode' ) ) {
11
+ return Jetpack::is_development_mode();
12
+ }
13
+
14
+ return false;
15
+ }
16
+
17
+ /**
18
+ * Helper method to get if Jetpack is connected (aka active)
19
+ * @return bool
20
+ */
21
+ public static function is_active() {
22
+ if ( method_exists( 'Jetpack', 'is_active' ) ) {
23
+ return Jetpack::is_active();
24
+ }
25
+
26
+ return false;
27
+ }
28
+
29
+ /**
30
+ * Helper method to get if the current Jetpack website is marked as staging
31
+ * @return bool
32
+ */
33
+ public static function is_staging_site() {
34
+ if ( method_exists( '\\Automattic\\Jetpack\\Status', 'is_staging_site' ) ) {
35
+ return ( new \Automattic\Jetpack\Status )->is_staging_site();
36
+ }
37
+
38
+ if ( method_exists( 'Jetpack', 'is_staging_site' ) ) {
39
+ return Jetpack::is_staging_site();
40
+ }
41
+
42
+ return false;
43
+ }
44
+
45
+ /**
46
+ * Helper method to get whether the current site is an Atomic site
47
+ * @return bool
48
+ */
49
+ public static function is_atomic_site() {
50
+ if ( function_exists( 'jetpack_is_atomic_site' ) ) {
51
+ return jetpack_is_atomic_site();
52
+ } elseif ( function_exists( 'jetpack_is_automated_transfer_site' ) ) {
53
+ return jetpack_is_automated_transfer_site();
54
+ }
55
+
56
+ return false;
57
+ }
58
+
59
+ public static function get_connected_user_data( $user_id ) {
60
+ if ( method_exists( 'Jetpack', 'get_connected_user_data' ) ) {
61
+ return Jetpack::get_connected_user_data( $user_id );
62
+ }
63
+
64
+ return false;
65
+ }
66
+
67
+ /**
68
+ * Helper method to get the Jetpack master user, IF we are connected
69
+ * @return WP_User | false
70
+ */
71
+ public static function get_master_user() {
72
+ include_once ( ABSPATH . 'wp-admin/includes/plugin.php' );
73
+ if ( self::is_active() && method_exists( 'Jetpack_Options', 'get_option' ) ) {
74
+ $master_user_id = Jetpack_Options::get_option( 'master_user' );
75
+ return get_userdata( $master_user_id );
76
+ }
77
+
78
+ return false;
79
+ }
80
+
81
+ /**
82
+ * Builds a connect url
83
+ * @param $redirect_url
84
+ * @return string
85
+ */
86
+ public static function build_connect_url( $redirect_url ) {
87
+ return Jetpack::init()->build_connect_url(
88
+ true,
89
+ $redirect_url,
90
+ 'woocommerce-services-auto-authorize'
91
+ );
92
+ }
93
+
94
+ /**
95
+ * Records a Tracks event
96
+ * @param $user
97
+ * @param $event_type
98
+ * @param
99
+ */
100
+ public static function tracks_record_event( $user, $event_type, $data ) {
101
+ if ( version_compare( JETPACK__VERSION, '7.5', '<' ) ) {
102
+ if ( function_exists( 'jetpack_tracks_record_event' ) ) {
103
+ return jetpack_tracks_record_event( $user, $event_type, $data );
104
+ }
105
+ } elseif ( class_exists( 'Automattic\\Jetpack\\Tracking' ) ) {
106
+ $tracking = new Automattic\Jetpack\Tracking();
107
+ return $tracking->tracks_record_event( $user, $event_type, $data );
108
+ }
109
+ return false;
110
+ }
111
+ }
112
+ }
trunk/classes/class-wc-connect-label-reports.php ADDED
@@ -0,0 +1,224 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Label_Reports' ) ) {
4
+ include_once( WC()->plugin_path() . '/includes/admin/reports/class-wc-admin-report.php' );
5
+
6
+ class WC_Connect_Label_Reports extends WC_Admin_Report {
7
+ const LABELS_TRANSIENT_KEY = 'wcs_label_reports';
8
+
9
+ /**
10
+ * @var WC_Connect_Service_Settings_Store
11
+ */
12
+ protected $settings_store;
13
+
14
+ public function __construct( WC_Connect_Service_Settings_Store $settings_store ) {
15
+ $this->settings_store = $settings_store;
16
+ }
17
+
18
+ public function get_export_button() {
19
+ $current_range = ! empty( $_GET['range'] ) ? sanitize_text_field( $_GET['range'] ) : '7day';
20
+ ?>
21
+ <a
22
+ href="#"
23
+ download="report-shipping-labels-<?php echo esc_attr( $current_range ); ?>-<?php echo date_i18n( 'Y-m-d', current_time( 'timestamp' ) ); ?>.csv"
24
+ class="export_csv"
25
+ data-export="table"
26
+ >
27
+ <?php _e( 'Export CSV', 'woocommerce-services' ); ?>
28
+ </a>
29
+ <?php
30
+ }
31
+
32
+ private function compare_label_dates_desc( $label_a, $label_b ) {
33
+ return $label_b['created'] - $label_a['created'];
34
+ }
35
+
36
+ private function get_all_labels() {
37
+ global $wpdb;
38
+ $query = "SELECT post_id, meta_value FROM {$wpdb->postmeta} WHERE meta_key = 'wc_connect_labels'";
39
+ $db_results = $wpdb->get_results( $query );
40
+ $results = array();
41
+
42
+ foreach ( $db_results as $meta ) {
43
+ $labels = maybe_unserialize( $meta->meta_value );
44
+
45
+ if ( ! is_array( $labels ) ) {
46
+ $labels = $this->settings_store->try_deserialize_labels_json( $meta->meta_value );
47
+ }
48
+
49
+ if ( empty( $labels ) ) {
50
+ continue;
51
+ }
52
+
53
+ foreach ( $labels as $label ) {
54
+ $results[] = array_merge( $label, array( 'order_id' => $meta->post_id ) );
55
+ }
56
+ }
57
+
58
+ usort( $results, array( $this, 'compare_label_dates_desc' ) );
59
+ return $results;
60
+ }
61
+
62
+ private function query_labels() {
63
+ $all_labels = get_transient( self::LABELS_TRANSIENT_KEY );
64
+ if ( false === $all_labels ) {
65
+ $all_labels = $this->get_all_labels();
66
+ //set transient with ttl of 30 minutes
67
+ set_transient( self::LABELS_TRANSIENT_KEY, $all_labels, 1800 );
68
+ }
69
+
70
+ // translate timestamps to JS timestapms
71
+ $start_date = $this->start_date * 1000;
72
+ $end_date = $this->end_date * 1000;
73
+
74
+ $results = array();
75
+ foreach ( $all_labels as $label ) {
76
+ $created = $label['created'];
77
+ if ( $created > $end_date ) {
78
+ continue;
79
+ }
80
+
81
+ //labels are sorted in descending order, so if we reached the end, break the loop
82
+ if ( $created < $start_date ) {
83
+ break;
84
+ }
85
+
86
+ if ( isset( $label['error'] ) || //ignore the error labels
87
+ ! isset( $label['rate'] ) ) { //labels where purchase hasn't completed for any reason
88
+ continue;
89
+ }
90
+
91
+ //ignore labels with complete refunds
92
+ if ( isset( $label['refund'] ) ) {
93
+ $refund = ( array ) $label['refund'];
94
+ if ( isset( $refund['status'] ) && 'completed' === $refund['status'] ) {
95
+ continue;
96
+ }
97
+ }
98
+
99
+ $results[] = $label;
100
+ }
101
+
102
+ return $results;
103
+ }
104
+
105
+ public function output_report() {
106
+ $ranges = array(
107
+ 'year' => __( 'Year', 'woocommerce-services' ),
108
+ 'last_month' => __( 'Last month', 'woocommerce-services' ),
109
+ 'month' => __( 'This month', 'woocommerce-services' ),
110
+ '7day' => __( 'Last 7 days', 'woocommerce-services' ),
111
+ );
112
+
113
+ $current_range = ! empty( $_GET['range'] ) ? sanitize_text_field( $_GET['range'] ) : '7day';
114
+
115
+ if ( ! in_array( $current_range, array( 'custom', 'year', 'last_month', 'month', '7day' ) ) ) {
116
+ $current_range = '7day';
117
+ }
118
+
119
+ $this->check_current_range_nonce( $current_range );
120
+ $this->calculate_current_range( $current_range );
121
+
122
+ $hide_sidebar = true;
123
+
124
+ include( WC()->plugin_path() . '/includes/admin/views/html-report-by-date.php' );
125
+ }
126
+
127
+ private function get_order_url( $post_id ) {
128
+ $order = wc_get_order( $post_id );
129
+ return '<a href="' . WC_Connect_Compatibility::instance()->get_edit_order_url( $order ) . '">' . $order->get_order_number( $order ) . '</a>';
130
+ }
131
+
132
+ private function get_label_refund_status( $label ) {
133
+ if ( ! isset( $label['refund'] ) ) {
134
+ return '';
135
+ }
136
+
137
+ $refund = ( array ) $label['refund'];
138
+
139
+ if ( isset( $refund['status'] ) &&
140
+ ( 'rejected' === $refund['status'] || 'complete' === $refund['status'] ) ) {
141
+ return '';
142
+ }
143
+
144
+ return __( 'Requested', 'woocommerce-services' );
145
+ }
146
+
147
+ /**
148
+ * Get the main chart.
149
+ */
150
+ public function get_main_chart() {
151
+ $labels = $this->query_labels();
152
+
153
+ ?>
154
+ <table class="widefat">
155
+ <thead>
156
+ <tr>
157
+ <th>
158
+ <?php esc_html_e( 'Time', 'woocommerce-services' ); ?>
159
+ </th>
160
+ <th>
161
+ <?php esc_html_e( 'Order', 'woocommerce-services' ); ?>
162
+ </th>
163
+ <th>
164
+ <?php esc_html_e( 'Price', 'woocommerce-services' ); ?>
165
+ </th>
166
+ <th>
167
+ <?php esc_html_e( 'Service', 'woocommerce-services' ); ?>
168
+ </th>
169
+ <th>
170
+ <?php esc_html_e( 'Refund', 'woocommerce-services' ); ?>
171
+ </th>
172
+ </tr>
173
+ </thead>
174
+ <?php if ( ! empty( $labels ) ) : ?>
175
+ <tbody>
176
+ <?php foreach ( $labels as $label ) : ?>
177
+ <tr>
178
+ <th scope="row">
179
+ <?php echo get_date_from_gmt( date( 'Y-m-d H:i:s', $label['created'] / 1000 ) ); ?>
180
+ </th>
181
+ <td>
182
+ <?php echo $this->get_order_url( $label['order_id'] ); ?>
183
+ </td>
184
+ <td>
185
+ <?php echo wc_price( $label['rate'] ); ?>
186
+ </td>
187
+ <td>
188
+ <?php echo $label['service_name']; ?>
189
+ </td>
190
+ <td>
191
+ <?php echo $this->get_label_refund_status( $label ); ?>
192
+ </td>
193
+ </tr>
194
+ <?php endforeach; ?>
195
+ </tbody>
196
+ <tfoot>
197
+ <?php
198
+ $total = array_sum( wp_list_pluck( $labels, 'rate' ) );
199
+ ?>
200
+ <tr>
201
+ <th scope="row">
202
+ <?php _e( 'Total', 'woocommerce-services' ); ?>
203
+ </th>
204
+ <th>
205
+ <?php echo count( $labels ); ?>
206
+ </th>
207
+ <th>
208
+ <?php echo wc_price( $total ); ?>
209
+ </th>
210
+ <th></th>
211
+ <th></th>
212
+ </tr>
213
+ <?php else : ?>
214
+ <tbody>
215
+ <tr>
216
+ <td><?php esc_html_e( 'No labels found for this period', 'woocommerce-services' ); ?></td>
217
+ </tr>
218
+ </tbody>
219
+ <?php endif; ?>
220
+ </table>
221
+ <?php
222
+ }
223
+ }
224
+ }
trunk/classes/class-wc-connect-logger.php ADDED
@@ -0,0 +1,135 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Logger' ) ) {
4
+
5
+ class WC_Connect_Logger {
6
+
7
+ /**
8
+ * @var WC_Logger
9
+ */
10
+ private $logger;
11
+
12
+ private $is_logging_enabled = false;
13
+ private $is_debug_enabled = false;
14
+
15
+ private $feature;
16
+
17
+ public function __construct( WC_Logger $logger, $feature = '' ) {
18
+
19
+ $this->logger = $logger;
20
+ $this->feature = strtolower( $feature );
21
+
22
+ $this->is_logging_enabled = WC_Connect_Options::get_option( 'debug_logging_enabled', false );
23
+ $this->is_debug_enabled = WC_Connect_Options::get_option( 'debug_display_enabled', false );
24
+
25
+ }
26
+
27
+ /**
28
+ * Format a message with optional context for logging.
29
+ *
30
+ * @param string|WP_Error $message Either a string message, or WP_Error object.
31
+ * @param string $context Optional. Context for the logged message.
32
+ * @return string The formatted log message.
33
+ */
34
+ protected function format_message( $message, $context = '' ) {
35
+
36
+ $formatted_message = $message;
37
+
38
+ if ( is_wp_error( $message ) ) {
39
+ $formatted_message = $message->get_error_code() . ' ' . $message->get_error_message();
40
+ }
41
+
42
+ if ( ! empty( $context ) ) {
43
+ $formatted_message .= ' (' . $context . ')';
44
+ }
45
+
46
+ return $formatted_message;
47
+
48
+ }
49
+
50
+ public function enable_logging() {
51
+ WC_Connect_Options::update_option( 'debug_logging_enabled', true );
52
+ $this->is_logging_enabled = true;
53
+ $this->log( "Logging enabled" );
54
+ }
55
+
56
+ public function disable_logging() {
57
+ $this->log( "Logging disabled" );
58
+ WC_Connect_Options::update_option( 'debug_logging_enabled', false );
59
+ $this->is_logging_enabled = false;
60
+ }
61
+
62
+ public function enable_debug() {
63
+ WC_Connect_Options::update_option( 'debug_display_enabled', true );
64
+ $this->is_debug_enabled = true;
65
+ $this->log( 'Debug enabled' );
66
+ }
67
+
68
+ public function disable_debug() {
69
+ $this->log( 'Debug disabled' );
70
+ WC_Connect_Options::update_option( 'debug_display_enabled', false );
71
+ $this->is_debug_enabled = false;
72
+ }
73
+
74
+ public function is_debug_enabled() {
75
+ return $this->is_debug_enabled;
76
+ }
77
+
78
+ public function is_logging_enabled() {
79
+ return $this->is_logging_enabled;
80
+ }
81
+
82
+ /**
83
+ * Log debug by printing it as notice when debugging is enabled.
84
+ *
85
+ * @param string $message Debug message.
86
+ * @param string $type Notice type.
87
+ */
88
+ public function debug( $message, $type = 'notice' ) {
89
+ if ( $this->is_debug_enabled() ) {
90
+ wc_add_notice( $message, $type );
91
+ }
92
+ }
93
+
94
+ /**
95
+ * Logs messages even if debugging is disabled
96
+ *
97
+ * @param string $message Message to log
98
+ * @param string $context Optional context (e.g. a class or function name)
99
+ */
100
+ public function error( $message, $context = '' ) {
101
+ WC_Connect_Error_Notice::instance()->enable_notice( $message );
102
+ $this->log( $message, $context, true );
103
+ }
104
+
105
+ /**
106
+ * Logs messages to file and error_log if WP_DEBUG
107
+ *
108
+ * @param string $message Message to log
109
+ * @param string $context Optional context (e.g. a class or function name)
110
+ */
111
+ public function log( $message, $context = '', $force = false ) {
112
+ $log_message = $this->format_message( $message, $context );
113
+
114
+ if ( defined( 'WP_DEBUG' ) && WP_DEBUG ) {
115
+ error_log( $log_message );
116
+ }
117
+
118
+ if ( ! $this->is_logging_enabled() && ! $force ) {
119
+ return;
120
+ }
121
+
122
+ $log_file = 'wc-services';
123
+
124
+ if ( ! empty( $this->feature ) ) {
125
+ $log_file .= '-' . $this->feature;
126
+ }
127
+
128
+ $this->logger->add( $log_file, $log_message );
129
+
130
+
131
+ }
132
+
133
+ }
134
+
135
+ }
trunk/classes/class-wc-connect-nux.php ADDED
@@ -0,0 +1,715 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Nux' ) ) {
4
+
5
+ class WC_Connect_Nux {
6
+ /**
7
+ * Jetpack status constants.
8
+ */
9
+ const JETPACK_NOT_INSTALLED = 'uninstalled';
10
+ const JETPACK_INSTALLED_NOT_ACTIVATED = 'installed';
11
+ const JETPACK_ACTIVATED_NOT_CONNECTED = 'activated';
12
+ const JETPACK_DEV = 'dev';
13
+ const JETPACK_CONNECTED = 'connected';
14
+
15
+ const IS_NEW_LABEL_USER = 'wcc_is_new_label_user';
16
+
17
+ /**
18
+ * Option name for dismissing success banner
19
+ * after the JP connection flow
20
+ */
21
+ const SHOULD_SHOW_AFTER_CXN_BANNER = 'should_display_nux_after_jp_cxn_banner';
22
+
23
+ /**
24
+ * @var WC_Connect_Tracks
25
+ */
26
+ protected $tracks;
27
+
28
+ /**
29
+ * @var WC_Connect_Shipping_Label
30
+ */
31
+ private $shipping_label;
32
+
33
+ function __construct( WC_Connect_Tracks $tracks, WC_Connect_Shipping_Label $shipping_label ) {
34
+ $this->tracks = $tracks;
35
+ $this->shipping_label = $shipping_label;
36
+
37
+ $this->init_pointers();
38
+ }
39
+
40
+ private function get_notice_states() {
41
+ $states = get_user_meta( get_current_user_id(), 'wc_connect_nux_notices', true );
42
+
43
+ if ( ! is_array( $states ) ) {
44
+ return array();
45
+ }
46
+
47
+ return $states;
48
+ }
49
+
50
+ public function is_notice_dismissed( $notice ) {
51
+ $notices = $this->get_notice_states();
52
+
53
+ return isset( $notices[ $notice ] ) && $notices[ $notice ];
54
+ }
55
+
56
+ public function dismiss_notice( $notice ) {
57
+ $notices = $this->get_notice_states();
58
+ $notices[ $notice ] = true;
59
+ update_user_meta( get_current_user_id(), 'wc_connect_nux_notices', $notices );
60
+ }
61
+
62
+ public function ajax_dismiss_notice() {
63
+ if ( empty( $_POST['dismissible_id'] ) ) {
64
+ return;
65
+ }
66
+
67
+ check_ajax_referer( 'wc_connect_dismiss_notice', 'nonce' );
68
+ $this->dismiss_notice( sanitize_key( $_POST['dismissible_id'] ) );
69
+ wp_die();
70
+ }
71
+
72
+ private function init_pointers() {
73
+ add_filter( 'wc_services_pointer_post.php', array( $this, 'register_order_page_labels_pointer' ) );
74
+ }
75
+
76
+ public function show_pointers( $hook ) {
77
+ /* Get admin pointers for the current admin page.
78
+ *
79
+ * @since 0.9.6
80
+ *
81
+ * @param array $pointers Array of pointers.
82
+ */
83
+ $pointers = apply_filters( 'wc_services_pointer_' . $hook, array() );
84
+
85
+ if ( ! $pointers || ! is_array( $pointers ) ) {
86
+ return;
87
+ }
88
+
89
+ $dismissed_pointers = $this->get_dismissed_pointers();
90
+ $valid_pointers = array();
91
+
92
+ foreach ( $pointers as $pointer ) {
93
+ if ( ! in_array( $pointer['id'], $dismissed_pointers, true ) ) {
94
+ $valid_pointers[] = $pointer;
95
+ }
96
+ }
97
+
98
+ if ( empty( $valid_pointers ) ) {
99
+ return;
100
+ }
101
+
102
+ wp_enqueue_style( 'wp-pointer' );
103
+ wp_localize_script( 'wc_services_admin_pointers', 'wcServicesAdminPointers', $valid_pointers );
104
+ wp_enqueue_script( 'wc_services_admin_pointers' );
105
+ }
106
+
107
+ public function get_dismissed_pointers() {
108
+ $data = get_user_meta( get_current_user_id(), 'dismissed_wp_pointers', true );
109
+ if ( is_string( $data ) && 0 < strlen( $data ) ) {
110
+ return explode( ',', $data );
111
+ }
112
+ return array();
113
+ }
114
+
115
+ /**
116
+ * Dismiss a WP pointer for the current user.
117
+ *
118
+ * @param string $pointer_to_dismiss Pointer ID to dismiss for the current user
119
+ */
120
+ public function dismiss_pointer( $pointer_to_dismiss ) {
121
+ $dismissed_pointers = $this->get_dismissed_pointers();
122
+
123
+ if ( in_array( $pointer_to_dismiss, $dismissed_pointers, true ) ) {
124
+ return;
125
+ }
126
+
127
+ $dismissed_pointers[] = $pointer_to_dismiss;
128
+ $dismissed_data = implode( ',', $dismissed_pointers );
129
+ update_user_meta( get_current_user_id(), 'dismissed_wp_pointers', $dismissed_data );
130
+ }
131
+
132
+ public function is_new_labels_user() {
133
+ $is_new_user = get_transient( self::IS_NEW_LABEL_USER );
134
+ if ( false === $is_new_user ) {
135
+ global $wpdb;
136
+ $query = "SELECT meta_key FROM {$wpdb->postmeta} WHERE meta_key = 'wc_connect_labels' LIMIT 1";
137
+ $results = $wpdb->get_results( $query );
138
+ $is_new_user = 0 === count( $results ) ? 'yes' : 'no';
139
+ set_transient( self::IS_NEW_LABEL_USER, $is_new_user );
140
+ }
141
+
142
+ return 'yes' === $is_new_user;
143
+ }
144
+
145
+ public function register_order_page_labels_pointer( $pointers ) {
146
+ // If the user is not new to labels, we should just dismiss this pointer
147
+ if ( ! $this->is_new_labels_user() ) {
148
+ $this->dismiss_pointer( 'wc_services_labels_metabox' );
149
+ return $pointers;
150
+ }
151
+
152
+ if ( $this->shipping_label->should_show_meta_box() ) {
153
+ $pointers[] = array(
154
+ 'id' => 'wc_services_labels_metabox',
155
+ 'target' => '#woocommerce-order-label .button',
156
+ 'options' => array(
157
+ 'content' => sprintf( '<h3>%s</h3><p>%s</p>',
158
+ __( 'Discounted Shipping Labels' ,'woocommerce-services' ),
159
+ __( "When you're ready, purchase and print discounted labels from USPS right here.", 'woocommerce-services' )
160
+ ),
161
+ 'position' => array( 'edge' => 'top', 'align' => 'left' ),
162
+ ),
163
+ 'dim' => true,
164
+ );
165
+ }
166
+
167
+ return $pointers;
168
+ }
169
+
170
+ /**
171
+ * Check that the current user is the owner of the Jetpack connection
172
+ * - Only that person can accept the TOS
173
+ *
174
+ * @uses self::get_jetpack_install_status()
175
+ *
176
+ * @return bool
177
+ */
178
+ public function can_accept_tos() {
179
+ $jetpack_status = $this->get_jetpack_install_status();
180
+
181
+ if (
182
+ ( self::JETPACK_NOT_INSTALLED === $jetpack_status ) ||
183
+ ( self::JETPACK_INSTALLED_NOT_ACTIVATED === $jetpack_status )
184
+ ) {
185
+ return false;
186
+ }
187
+
188
+ // Developer case
189
+ if ( self::JETPACK_DEV === $jetpack_status ) {
190
+ return true;
191
+ }
192
+
193
+ $user_token = Jetpack_Data::get_access_token( JETPACK_MASTER_USER );
194
+ $can_accept = (
195
+ isset( $user_token->external_user_id ) &&
196
+ get_current_user_id() === $user_token->external_user_id
197
+ );
198
+
199
+ return $can_accept;
200
+ }
201
+
202
+ public static function get_banner_type_to_display( $status = array() ) {
203
+ if ( ! isset( $status['jetpack_connection_status'] ) ) {
204
+ return false;
205
+ }
206
+
207
+ /* The NUX Flow:
208
+ - Case 1: Jetpack not connected (with TOS or no TOS accepted):
209
+ 1. show_banner_before_connection()
210
+ 2. connect to JP
211
+ 3. show_banner_after_connection(), which sets the TOS acceptance in options
212
+ - Case 2: Jetpack connected, no TOS
213
+ 1. show_tos_only_banner(), which accepts TOS on button click
214
+ - Case 3: Jetpack connected, and TOS accepted
215
+ This is an existing user. Do nothing.
216
+ */
217
+ switch ( $status['jetpack_connection_status'] ) {
218
+ case self::JETPACK_NOT_INSTALLED:
219
+ case self::JETPACK_INSTALLED_NOT_ACTIVATED:
220
+ case self::JETPACK_ACTIVATED_NOT_CONNECTED:
221
+ return 'before_jetpack_connection';
222
+ case self::JETPACK_CONNECTED:
223
+ case self::JETPACK_DEV:
224
+ // Has the user just gone through our NUX connection flow?
225
+ if ( isset( $status['should_display_after_cxn_banner'] ) && $status['should_display_after_cxn_banner'] ) {
226
+ return 'after_jetpack_connection';
227
+ }
228
+
229
+ // Has the user already accepted our TOS? Then do nothing.
230
+ // Note: TOS is accepted during the after_connection banner
231
+ if (
232
+ isset( $status['tos_accepted'] )
233
+ && ! $status['tos_accepted']
234
+ && isset( $status['can_accept_tos'] )
235
+ && $status['can_accept_tos']
236
+ ) {
237
+ return 'tos_only_banner';
238
+ }
239
+
240
+ return false;
241
+ default:
242
+ return false;
243
+ }
244
+ }
245
+
246
+ public function get_jetpack_install_status() {
247
+ // we need to use validate_plugin to check that Jetpack is installed
248
+ include_once( ABSPATH . 'wp-admin/includes/plugin.php' );
249
+
250
+ // check if jetpack is installed
251
+ if ( 0 !== validate_plugin( 'jetpack/jetpack.php' ) ) {
252
+ return self::JETPACK_NOT_INSTALLED;
253
+ }
254
+
255
+ // check if Jetpack is activated
256
+ if ( ! class_exists( 'Jetpack_Data' ) ) {
257
+ return self::JETPACK_INSTALLED_NOT_ACTIVATED;
258
+ }
259
+
260
+ if ( defined( 'JETPACK_DEV_DEBUG' ) && true === JETPACK_DEV_DEBUG ) {
261
+ // installed, activated, and dev mode on
262
+ return self::JETPACK_DEV;
263
+ }
264
+
265
+ // installed, activated, dev mode off
266
+ // check if connected
267
+ $user_token = Jetpack_Data::get_access_token( JETPACK_MASTER_USER );
268
+ if ( ! isset( $user_token->external_user_id ) ) { // always an int
269
+ return self::JETPACK_ACTIVATED_NOT_CONNECTED;
270
+ }
271
+
272
+ return self::JETPACK_CONNECTED;
273
+ }
274
+
275
+ public function should_display_nux_notice_on_screen( $screen ) {
276
+ if ( // Display if on any of these admin pages.
277
+ ( // Products list.
278
+ 'product' === $screen->post_type
279
+ && 'edit' === $screen->base
280
+ )
281
+ || ( // Orders list.
282
+ 'shop_order' === $screen->post_type
283
+ && 'edit' === $screen->base
284
+ )
285
+ || ( // Edit order page.
286
+ 'shop_order' === $screen->post_type
287
+ && 'post' === $screen->base
288
+ )
289
+ || ( // WooCommerce settings.
290
+ 'woocommerce_page_wc-settings' === $screen->base
291
+ )
292
+ || ( // WooCommerce featured extension page
293
+ 'woocommerce_page_wc-addons' === $screen->base
294
+ && isset( $_GET['section'] ) && 'featured' === $_GET['section']
295
+ )
296
+ || ( // WooCommerce shipping extension page
297
+ 'woocommerce_page_wc-addons' === $screen->base
298
+ && isset( $_GET['section'] ) && 'shipping_methods' === $_GET['section']
299
+ )
300
+ || 'plugins' === $screen->base
301
+ ) {
302
+ return true;
303
+ }
304
+ return false;
305
+ }
306
+
307
+ /**
308
+ * https://stripe.com/global
309
+ */
310
+ public function is_stripe_supported_country( $country_code ) {
311
+ $stripe_supported_countries = array(
312
+ 'AU',
313
+ 'AT',
314
+ 'BE',
315
+ 'CA',
316
+ 'DK',
317
+ 'FI',
318
+ 'FR',
319
+ 'DE',
320
+ 'HK',
321
+ 'IE',
322
+ 'JP',
323
+ 'LU',
324
+ 'NL',
325
+ 'NZ',
326
+ 'NO',
327
+ 'SG',
328
+ 'ES',
329
+ 'SE',
330
+ 'CH',
331
+ 'GB',
332
+ 'US',
333
+ );
334
+
335
+ return in_array( $country_code, $stripe_supported_countries );
336
+ }
337
+
338
+ /**
339
+ * https://developers.taxjar.com/api/reference/#countries
340
+ */
341
+ public function is_taxjar_supported_country( $country_code ) {
342
+ $taxjar_supported_countries = array_merge(
343
+ array(
344
+ 'US',
345
+ 'CA',
346
+ 'AU',
347
+ ),
348
+ WC()->countries->get_european_union_countries()
349
+ );
350
+
351
+ return in_array( $country_code, $taxjar_supported_countries );
352
+ }
353
+
354
+ public function should_display_nux_notice_for_current_store_locale() {
355
+ $store_country = WC()->countries->get_base_country();
356
+
357
+ $supports_stripe = $this->is_stripe_supported_country( $store_country );
358
+ $supports_taxes = $this->is_taxjar_supported_country( $store_country );
359
+ $supports_shipping = in_array( $store_country, array( 'US', 'CA' ) );
360
+
361
+ return $supports_shipping || $supports_stripe || $supports_taxes;
362
+ }
363
+
364
+ public function get_feature_list_for_country( $country ) {
365
+ $feature_list = false;
366
+ $supports_stripe = $this->is_stripe_supported_country( $country );
367
+ $supports_taxes = $this->is_taxjar_supported_country( $country );
368
+ $supports_labels = ( 'US' === $country );
369
+
370
+ $is_stripe_active = is_plugin_active( 'woocommerce-gateway-stripe/woocommerce-gateway-stripe.php' );
371
+ $stripe_settings = get_option( 'woocommerce_stripe_settings', array() );
372
+ $is_stripe_ready = $is_stripe_active && isset( $stripe_settings['enabled'] ) && 'yes' === $stripe_settings['enabled'];
373
+
374
+ $is_ppec_active = is_plugin_active( 'woocommerce-gateway-paypal-express-checkout/woocommerce-gateway-paypal-express-checkout.php' );
375
+ $ppec_settings = get_option( 'woocommerce_ppec_paypal_settings', array() );
376
+ $is_ppec_ready = $is_ppec_active && ( ! isset( $ppec_settings['enabled'] ) || 'yes' === $ppec_settings['enabled'] );
377
+
378
+ $supports_payments = ( $supports_stripe && $is_stripe_ready ) || $is_ppec_ready;
379
+
380
+ if ( $supports_payments && $supports_taxes && $supports_labels ) {
381
+ $feature_list = __( 'automated tax calculation, shipping label printing, and smoother payment setup', 'woocommerce-services' );
382
+ } elseif ( $supports_payments && $supports_taxes ) {
383
+ $feature_list = __( 'automated tax calculation and smoother payment setup', 'woocommerce-services' );
384
+ } else if ( $supports_taxes && $supports_labels ) {
385
+ $feature_list = __( 'automated tax calculation and shipping label printing', 'woocommerce-services' );
386
+ } else if ( $supports_payments && $supports_labels ) {
387
+ $feature_list = __( 'shipping label printing and smoother payment setup', 'woocommerce-services' );
388
+ } else if ( $supports_payments ) {
389
+ $feature_list = __( 'smoother payment setup', 'woocommerce-services' );
390
+ } else if ( $supports_taxes ) {
391
+ $feature_list = __( 'automated tax calculation', 'woocommerce-services' );
392
+ } else if ( $supports_labels ) {
393
+ $feature_list = __( 'shipping label printing', 'woocommerce-services' );
394
+ }
395
+
396
+ return $feature_list;
397
+ }
398
+
399
+ public function get_jetpack_redirect_url() {
400
+ $full_path = add_query_arg( array() );
401
+ // Remove [...]/wp-admin so we can use admin_url().
402
+ $new_index = strpos( $full_path, '/wp-admin' ) + strlen( '/wp-admin' );
403
+ $path = substr( $full_path, $new_index );
404
+ return admin_url( $path );
405
+ }
406
+
407
+ public function set_up_nux_notices() {
408
+ if ( ! current_user_can( 'manage_woocommerce' ) ) {
409
+ return;
410
+ }
411
+
412
+ // Check for plugin install and activate permissions to handle Jetpack on multisites:
413
+ // Admins might not be able to install or activate plugins, but Jetpack might already have been installed by a superadmin.
414
+ // If this is the case, the admin can connect the site on their own, and should be able to use WCS as ususal
415
+ $jetpack_install_status = $this->get_jetpack_install_status();
416
+ if ( ( self::JETPACK_NOT_INSTALLED === $jetpack_install_status && ! current_user_can( 'install_plugins' ) )
417
+ || ( self::JETPACK_INSTALLED_NOT_ACTIVATED === $jetpack_install_status && ! current_user_can( 'activate_plugins' ) ) ) {
418
+ return;
419
+ }
420
+
421
+ $banner_to_display = self::get_banner_type_to_display( array(
422
+ 'jetpack_connection_status' => $jetpack_install_status,
423
+ 'tos_accepted' => WC_Connect_Options::get_option( 'tos_accepted' ),
424
+ 'can_accept_tos' => $this->can_accept_tos(),
425
+ 'should_display_after_cxn_banner' => WC_Connect_Options::get_option( self::SHOULD_SHOW_AFTER_CXN_BANNER ),
426
+ ) );
427
+
428
+ switch ( $banner_to_display ) {
429
+ case 'before_jetpack_connection':
430
+ $ajax_data = array(
431
+ 'nonce' => wp_create_nonce( 'wcs_nux_notice' ),
432
+ 'initial_install_status' => $jetpack_install_status,
433
+ 'redirect_url' => $this->get_jetpack_redirect_url(),
434
+ 'translations' => array(
435
+ 'activating' => __( 'Activating...', 'woocommerce-services' ),
436
+ 'connecting' => __( 'Connecting...', 'woocommerce-services' ),
437
+ 'installError' => __( 'There was an error installing Jetpack. Please try installing it manually.', 'woocommerce-services' ),
438
+ 'defaultError' => __( 'Something went wrong. Please try connecting to Jetpack manually, or contact support on the WordPress.org forums.', 'woocommerce-services' ),
439
+ ),
440
+ );
441
+ wp_enqueue_script( 'wc_connect_banner' );
442
+ wp_localize_script( 'wc_connect_banner', 'wcs_nux_notice', $ajax_data );
443
+ add_action( 'wp_ajax_woocommerce_services_activate_jetpack',
444
+ array( $this, 'ajax_activate_jetpack' )
445
+ );
446
+ add_action( 'wp_ajax_woocommerce_services_get_jetpack_connect_url',
447
+ array( $this, 'ajax_get_jetpack_connect_url' )
448
+ );
449
+ wp_enqueue_style( 'wc_connect_banner' );
450
+ add_action( 'admin_notices', array( $this, 'show_banner_before_connection' ), 9 );
451
+ break;
452
+ case 'tos_only_banner':
453
+ wp_enqueue_style( 'wc_connect_banner' );
454
+ add_action( 'admin_notices', array( $this, 'show_tos_banner' ) );
455
+ break;
456
+ case 'after_jetpack_connection':
457
+ wp_enqueue_style( 'wc_connect_banner' );
458
+ add_action( 'admin_notices', array( $this, 'show_banner_after_connection' ) );
459
+ break;
460
+ }
461
+
462
+ add_action( 'wp_ajax_wc_connect_dismiss_notice', array( $this, 'ajax_dismiss_notice' ) );
463
+ }
464
+
465
+ public function show_banner_before_connection() {
466
+ if ( ! $this->should_display_nux_notice_for_current_store_locale() ) {
467
+ return;
468
+ }
469
+
470
+ if ( ! $this->should_display_nux_notice_on_screen( get_current_screen() ) ) {
471
+ return;
472
+ }
473
+
474
+ // Remove Jetpack's connect banners since we're showing our own.
475
+ if ( class_exists( 'Jetpack_Connection_Banner' ) ) {
476
+ $jetpack_banner = Jetpack_Connection_Banner::init();
477
+
478
+ remove_action( 'admin_notices', array( $jetpack_banner, 'render_banner' ) );
479
+ remove_action( 'admin_notices', array( $jetpack_banner, 'render_connect_prompt_full_screen' ) );
480
+ }
481
+
482
+ // Make sure that we wait until the button is clicked before displaying
483
+ // the after_connection banner
484
+ // so that we don't accept the TOS pre-maturely
485
+ WC_Connect_Options::delete_option( self::SHOULD_SHOW_AFTER_CXN_BANNER );
486
+
487
+ $jetpack_status = $this->get_jetpack_install_status();
488
+ $button_text = __( 'Connect', 'woocommerce-services' );
489
+ $banner_title = __( 'Connect Jetpack to activate WooCommerce Services', 'woocommerce-services' );
490
+ $image_url = plugins_url( 'images/wcs-notice.png', dirname( __FILE__ ) );
491
+
492
+ switch ( $jetpack_status ) {
493
+ case self::JETPACK_NOT_INSTALLED:
494
+ $button_text = __( 'Install Jetpack and connect', 'woocommerce-services' );
495
+ break;
496
+ case self::JETPACK_INSTALLED_NOT_ACTIVATED:
497
+ $button_text = __( 'Activate Jetpack and connect', 'woocommerce-services' );
498
+ break;
499
+ }
500
+
501
+ $country = WC()->countries->get_base_country();
502
+ /* translators: %s: list of features, potentially comma separated */
503
+ $description_base = __( "WooCommerce Services is almost ready to go! Once you connect Jetpack you'll have access to %s.", 'woocommerce-services' );
504
+ $feature_list = $this->get_feature_list_for_country( $country );
505
+ $banner_content = array(
506
+ 'title' => $banner_title,
507
+ 'description' => sprintf( $description_base, $feature_list ),
508
+ 'button_text' => $button_text,
509
+ 'image_url' => $image_url,
510
+ 'should_show_jp' => true,
511
+ 'should_show_terms' => true,
512
+ );
513
+
514
+ $this->show_nux_banner( $banner_content );
515
+ }
516
+
517
+ public function show_banner_after_connection() {
518
+ if ( ! $this->should_display_nux_notice_for_current_store_locale() ) {
519
+ return;
520
+ }
521
+
522
+ if ( ! $this->should_display_nux_notice_on_screen( get_current_screen() ) ) {
523
+ return;
524
+ }
525
+
526
+ // Did the user just dismiss?
527
+ if ( isset( $_GET['wcs-nux-notice'] ) && 'dismiss' === $_GET['wcs-nux-notice'] ) {
528
+ // No longer need to keep track of whether the before connection banner was displayed.
529
+ WC_Connect_Options::delete_option( self::SHOULD_SHOW_AFTER_CXN_BANNER );
530
+ wp_safe_redirect( remove_query_arg( 'wcs-nux-notice' ) );
531
+ exit;
532
+ }
533
+
534
+ // By going through the connection process, the user has accepted our TOS
535
+ WC_Connect_Options::update_option( 'tos_accepted', true );
536
+
537
+ $this->tracks->opted_in( 'connection_banner' );
538
+
539
+ $country = WC()->countries->get_base_country();
540
+ /* translators: %s: list of features, potentially comma separated */
541
+ $description_base = __( 'You can now enjoy %s.', 'woocommerce-services' );
542
+ $feature_list = $this->get_feature_list_for_country( $country );
543
+
544
+ $this->show_nux_banner( array(
545
+ 'title' => __( 'Setup complete.', 'woocommerce-services' ),
546
+ 'description' => esc_html( sprintf( $description_base, $feature_list ) ),
547
+ 'button_text' => __( 'Got it, thanks!', 'woocommerce-services' ),
548
+ 'button_link' => add_query_arg( array(
549
+ 'wcs-nux-notice' => 'dismiss',
550
+ ) ),
551
+ 'image_url' => plugins_url(
552
+ 'images/wcs-notice.png', dirname( __FILE__ )
553
+ ),
554
+ 'should_show_jp' => false,
555
+ 'should_show_terms' => false,
556
+ ) );
557
+ }
558
+
559
+ public function show_tos_banner() {
560
+ if ( ! $this->should_display_nux_notice_for_current_store_locale() ) {
561
+ return;
562
+ }
563
+
564
+ if ( ! $this->should_display_nux_notice_on_screen( get_current_screen() ) ) {
565
+ return;
566
+ }
567
+
568
+ if ( isset( $_GET['wcs-nux-tos'] ) && 'accept' === $_GET['wcs-nux-tos'] ) {
569
+ WC_Connect_Options::update_option( 'tos_accepted', true );
570
+
571
+ $this->tracks->opted_in( 'tos_banner' );
572
+
573
+ wp_safe_redirect( remove_query_arg( 'wcs-nux-tos' ) );
574
+ exit;
575
+ }
576
+
577
+ $country = WC()->countries->get_base_country();
578
+ /* translators: %s: list of features, potentially comma separated */
579
+ $description_base = __( "WooCommerce Services is almost ready to go! Once you connect your store you'll have access to %s.", 'woocommerce-services' );
580
+ $feature_list = $this->get_feature_list_for_country( $country );
581
+
582
+ $this->show_nux_banner( array(
583
+ 'title' => __( 'Connect your store to activate WooCommerce Services', 'woocommerce-services' ),
584
+ 'description' => esc_html( sprintf( $description_base, $feature_list ) ),
585
+ 'button_text' => __( 'Connect', 'woocommerce-services' ),
586
+ 'button_link' => add_query_arg( array(
587
+ 'wcs-nux-tos' => 'accept',
588
+ ) ),
589
+ 'image_url' => plugins_url(
590
+ 'images/wcs-notice.png', dirname( __FILE__ )
591
+ ),
592
+ 'should_show_jp' => false,
593
+ 'should_show_terms' => true,
594
+ ) );
595
+ }
596
+
597
+ public function show_nux_banner( $content ) {
598
+ if ( isset( $content['dismissible_id'] ) && $this->is_notice_dismissed( sanitize_key( $content['dismissible_id'] ) ) ) {
599
+ return;
600
+ }
601
+
602
+ ?>
603
+ <div class="notice wcs-nux__notice <?php echo isset( $content['dismissible_id'] ) ? 'is-dismissible' : ''; ?>">
604
+ <div class="wcs-nux__notice-logo <?php echo isset( $content['compact_logo'] ) && $content['compact_logo'] ? 'is-compact' : ''; ?>">
605
+ <?php if ( $content['should_show_jp'] ) : ?>
606
+ <img
607
+ class="wcs-nux__notice-logo-jetpack"
608
+ src="<?php echo esc_url( plugins_url( 'images/jetpack-logo.png', dirname( __FILE__ ) ) ); ?>"
609
+ >
610
+ <?php endif; ?>
611
+ <img class="wcs-nux__notice-logo-graphic" src="<?php echo esc_url( $content['image_url'] ); ?>">
612
+ </div>
613
+ <div class="wcs-nux__notice-content">
614
+ <h1 class="wcs-nux__notice-content-title">
615
+ <?php echo esc_html( $content['title'] ); ?>
616
+ </h1>
617
+ <p class="wcs-nux__notice-content-text">
618
+ <?php echo $content['description']; ?>
619
+ </p>
620
+ <?php if ( isset( $content['should_show_terms'] ) && $content['should_show_terms'] ) : ?>
621
+ <p class="wcs-nux__notice-content-tos"><?php
622
+ /* translators: %1$s example values include "Install Jetpack and CONNECT >", "Activate Jetpack and CONNECT >", "CONNECT >" */
623
+ printf(
624
+ wp_kses( __( 'By clicking "%1$s", you agree to the <a href="%2$s">Terms of Service</a> and to <a href="%3$s">share certain data and settings</a> with WordPress.com and/or third parties.', 'woocommerce-services' ),
625
+ array(
626
+ 'a' => array(
627
+ 'href' => array(),
628
+ ),
629
+ ) ),
630
+ esc_html( $content['button_text'] ),
631
+ 'https://wordpress.com/tos/',
632
+ 'https://jetpack.com/support/what-data-does-jetpack-sync/'
633
+ ); ?></p>
634
+ <?php endif; ?>
635
+ <?php if ( isset( $content['button_link'] ) ) : ?>
636
+ <a
637
+ class="wcs-nux__notice-content-button button button-primary"
638
+ href="<?php echo esc_url( $content['button_link'] ); ?>"
639
+ >
640
+ <?php echo esc_html( $content['button_text'] ); ?>
641
+ </a>
642
+ <?php else : ?>
643
+ <button
644
+ class="woocommerce-services__connect-jetpack wcs-nux__notice-content-button button button-primary"
645
+ >
646
+ <?php echo esc_html( $content['button_text'] ); ?>
647
+ </button>
648
+ <?php endif; ?>
649
+ </div>
650
+ </div>
651
+ <?php
652
+ if ( isset( $content['dismissible_id'] ) ) :
653
+ // Add handler for dismissing banner. Only supports a single banner at a time
654
+ wp_enqueue_script( 'wp-util' );
655
+ ?>
656
+ <script>
657
+ ( function( $ ) {
658
+ $( '.wcs-nux__notice' ).on( 'click', '.notice-dismiss', function() {
659
+ wp.ajax.post( {
660
+ action: "wc_connect_dismiss_notice",
661
+ dismissible_id: "<?php echo esc_js( $content['dismissible_id'] ); ?>",
662
+ nonce: "<?php echo esc_js( wp_create_nonce( 'wc_connect_dismiss_notice' ) ); ?>"
663
+ } );
664
+ } );
665
+ } )( jQuery );
666
+ </script>
667
+ <?php
668
+ endif;
669
+ }
670
+
671
+ /**
672
+ * Activates Jetpack after an ajax request
673
+ */
674
+ public function ajax_activate_jetpack() {
675
+ check_ajax_referer( 'wcs_nux_notice' );
676
+
677
+ $result = activate_plugin( 'jetpack/jetpack.php' );
678
+
679
+ if ( is_null( $result ) ) {
680
+ // The function activate_plugin() returns NULL on success.
681
+ echo 'success';
682
+ } else {
683
+ if ( is_wp_error( $result ) ) {
684
+ echo esc_html( $result->get_error_message() );
685
+ } else {
686
+ echo 'error';
687
+ }
688
+ }
689
+
690
+ wp_die();
691
+ }
692
+
693
+ /**
694
+ * Get Jetpack connection URL.
695
+ *
696
+ */
697
+ public function ajax_get_jetpack_connect_url() {
698
+ check_ajax_referer( 'wcs_nux_notice' );
699
+
700
+ $redirect_url = '';
701
+ if ( isset( $_POST['redirect_url'] ) ) {
702
+ $redirect_url = esc_url_raw( wp_unslash( $_POST['redirect_url'] ) );
703
+ }
704
+
705
+ $connect_url = WC_Connect_Jetpack::build_connect_url( $redirect_url );
706
+
707
+ // Make sure we always display the after-connection banner
708
+ // after the before_connection button is clicked
709
+ WC_Connect_Options::update_option( self::SHOULD_SHOW_AFTER_CXN_BANNER, true );
710
+
711
+ echo esc_url_raw( $connect_url );
712
+ wp_die();
713
+ }
714
+ }
715
+ }
trunk/classes/class-wc-connect-options.php ADDED
@@ -0,0 +1,341 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Options' ) ) {
4
+ class WC_Connect_Options {
5
+ /**
6
+ * An array that maps a grouped option type to an option name.
7
+ * @var array
8
+ */
9
+ private static $grouped_options = array(
10
+ 'compact' => 'wc_connect_options',
11
+ );
12
+
13
+ /**
14
+ * Returns an array of option names for a given type.
15
+ *
16
+ * @param string $type The type of option to return. Defaults to 'compact'.
17
+ *
18
+ * @return array
19
+ */
20
+ public static function get_option_names( $type = 'compact' ) {
21
+ switch ( $type ) {
22
+ case 'non_compact':
23
+ return array(
24
+ 'error_notice',
25
+ 'services',
26
+ 'services_last_update',
27
+ 'last_heartbeat',
28
+ 'origin_address',
29
+ 'last_rate_request',
30
+ );
31
+ case 'shipping_method':
32
+ return array(
33
+ 'form_settings',
34
+ 'failure_timestamp',
35
+ );
36
+ }
37
+
38
+ return array(
39
+ 'tos_accepted',
40
+ 'store_guid',
41
+ 'debug_logging_enabled',
42
+ 'debug_display_enabled',
43
+ 'payment_methods',
44
+ 'account_settings',
45
+ 'paper_size',
46
+ 'packages',
47
+ 'predefined_packages',
48
+ 'shipping_methods_migrated',
49
+ 'should_display_nux_after_jp_cxn_banner',
50
+ 'needs_tax_environment_setup',
51
+ 'stripe_state',
52
+ 'banner_stripe',
53
+ 'banner_ppec',
54
+ 'stripe_keys',
55
+ 'stripe_status_migrated',
56
+ );
57
+ }
58
+
59
+ /**
60
+ * Deletes all options created by WooCommerce Services, including shipping method options
61
+ */
62
+ public static function delete_all_options() {
63
+ if ( defined( 'WOOCOMMERCE_CONNECT_DEV_SERVER_URL' ) ) {
64
+ return;
65
+ }
66
+
67
+ foreach( self::$grouped_options as $group_key => $group ) {
68
+ //delete legacy options
69
+ foreach ( self::get_option_names( $group_key ) as $group_option ) {
70
+ delete_option( "wc_connect_$group_option" );
71
+ }
72
+
73
+ delete_option( $group );
74
+ }
75
+
76
+ $non_compacts = self::get_option_names( 'non_compact' );
77
+ foreach ( $non_compacts as $non_compact ) {
78
+ delete_option( "wc_connect_$non_compact" );
79
+ }
80
+
81
+ self::delete_all_shipping_methods_options();
82
+ }
83
+
84
+ /**
85
+ * Returns the requested option. Looks in wc_connect_options or wc_connect_$name as appropriate.
86
+ *
87
+ * @param string $name Option name
88
+ * @param mixed $default (optional)
89
+ *
90
+ * @return mixed
91
+ */
92
+ public static function get_option( $name, $default = false ) {
93
+ if ( self::is_valid( $name, 'non_compact' ) ) {
94
+ return get_option( "wc_connect_$name", $default );
95
+ }
96
+
97
+ foreach ( array_keys( self::$grouped_options ) as $group ) {
98
+ if ( self::is_valid( $name, $group ) ) {
99
+ return self::get_grouped_option( $group, $name, $default );
100
+ }
101
+ }
102
+
103
+ trigger_error( sprintf( 'Invalid WooCommerce Services option name: %s', $name ), E_USER_WARNING );
104
+ return $default;
105
+ }
106
+
107
+ /**
108
+ * Updates the single given option. Updates wc_connect_options or wc_connect_$name as appropriate.
109
+ *
110
+ * @param string $name Option name
111
+ * @param mixed $value Option value
112
+ *
113
+ * @return bool Was the option successfully updated?
114
+ */
115
+ public static function update_option( $name, $value) {
116
+ if ( self::is_valid( $name, 'non_compact' ) ) {
117
+ return update_option( "wc_connect_$name", $value );
118
+ }
119
+ foreach ( array_keys( self::$grouped_options ) as $group ) {
120
+ if ( self::is_valid( $name, $group ) ) {
121
+ return self::update_grouped_option( $group, $name, $value );
122
+ }
123
+ }
124
+ trigger_error( sprintf( 'Invalid WooCommerce Services option name: %s', $name ), E_USER_WARNING );
125
+ return false;
126
+ }
127
+
128
+ /**
129
+ * Deletes the given option. May be passed multiple option names as an array.
130
+ * Updates wc_connect_options and/or deletes wc_connect_$name as appropriate.
131
+ *
132
+ * @param string|array $names
133
+ *
134
+ * @return bool Was the option successfully deleted?
135
+ */
136
+ public static function delete_option( $names ) {
137
+ $result = true;
138
+ $names = (array) $names;
139
+ if ( ! self::is_valid( $names ) ) {
140
+ trigger_error( sprintf( 'Invalid WooCommerce Services option names: %s', print_r( $names, 1 ) ), E_USER_WARNING );
141
+ return false;
142
+ }
143
+ foreach ( array_intersect( $names, self::get_option_names( 'non_compact' ) ) as $name ) {
144
+ if ( ! delete_option( "wc_connect_$name" ) ) {
145
+ $result = false;
146
+ }
147
+ }
148
+ foreach ( array_keys( self::$grouped_options ) as $group ) {
149
+ if ( ! self::delete_grouped_option( $group, $names ) ) {
150
+ $result = false;
151
+ }
152
+ }
153
+ return $result;
154
+ }
155
+
156
+ /**
157
+ * Gets a shipping method option
158
+ *
159
+ * @param $name
160
+ * @param $default
161
+ * @param $service_id
162
+ * @param $service_instance
163
+ *
164
+ * @return mixed
165
+ */
166
+ public static function get_shipping_method_option( $name, $default, $service_id, $service_instance = false ) {
167
+ $option_name = self::get_shipping_method_option_name( $name, $service_id, $service_instance );
168
+
169
+ if ( ! $option_name ) {
170
+ trigger_error( sprintf( 'Invalid WooCommerce Services shipping method option name: %s', $name ), E_USER_WARNING );
171
+ return $default;
172
+ }
173
+
174
+ return get_option( $option_name, $default );
175
+ }
176
+
177
+ /**
178
+ * Updates a shipping method option
179
+ *
180
+ * @param $name
181
+ * @param $value
182
+ * @param $service_id
183
+ * @param $service_instance
184
+ *
185
+ * @return bool
186
+ */
187
+ public static function update_shipping_method_option( $name, $value, $service_id, $service_instance = false ) {
188
+ $option_name = self::get_shipping_method_option_name( $name, $service_id, $service_instance );
189
+
190
+ if ( ! $option_name ) {
191
+ trigger_error( sprintf( 'Invalid WooCommerce Services shipping method option name: %s', $name ), E_USER_WARNING );
192
+ return false;
193
+ }
194
+
195
+ return update_option( $option_name, $value );
196
+ }
197
+
198
+ /**
199
+ * Deletes a shipping method option
200
+ *
201
+ * @param $name
202
+ * @param $service_id
203
+ * @param $service_instance
204
+ *
205
+ * @return bool
206
+ */
207
+ public static function delete_shipping_method_option( $name, $service_id, $service_instance = false ) {
208
+ $option_name = self::get_shipping_method_option_name( $name, $service_id, $service_instance );
209
+
210
+ if ( ! $option_name ) {
211
+ trigger_error( sprintf( 'Invalid WooCommerce Services shipping method option name: %s', $name ), E_USER_WARNING );
212
+ return false;
213
+ }
214
+
215
+ return delete_option( $option_name );
216
+ }
217
+
218
+ /**
219
+ * Deletes all options related to a shipping method
220
+ *
221
+ * @param $service_id
222
+ * @param $service_instance
223
+ */
224
+ public static function delete_shipping_method_options( $service_id, $service_instance = false ) {
225
+ $option_names = self::get_option_names( 'shipping_method' );
226
+
227
+ foreach ( $option_names as $name ) {
228
+ delete_option( self::get_shipping_method_option_name( $name, $service_id, $service_instance ) );
229
+ }
230
+ }
231
+
232
+ private static function get_grouped_option( $group, $name, $default ) {
233
+ $options = get_option( self::$grouped_options[ $group ] );
234
+ if ( is_array( $options ) && isset( $options[ $name ] ) ) {
235
+ return $options[ $name ];
236
+ }
237
+
238
+ //make the grouped options backwards-compatible and migrate the old options
239
+ $legacy_name = "wc_connect_$name";
240
+ $legacy_option = get_option( $legacy_name, false );
241
+ if ( ! $legacy_option ) {
242
+ return $default;
243
+ }
244
+ if ( self::update_grouped_option( $group, $name, $legacy_option ) ) {
245
+ delete_option( $legacy_name );
246
+ }
247
+
248
+ return $legacy_option;
249
+ }
250
+
251
+ private static function update_grouped_option( $group, $name, $value ) {
252
+ $options = get_option( self::$grouped_options[ $group ] );
253
+ if ( ! is_array( $options ) ) {
254
+ $options = array();
255
+ }
256
+ $options[ $name ] = $value;
257
+ return update_option( self::$grouped_options[ $group ], $options );
258
+ }
259
+
260
+ private static function delete_grouped_option( $group, $names ) {
261
+ $options = get_option( self::$grouped_options[ $group ], array() );
262
+ $to_delete = array_intersect( $names, self::get_option_names( $group ), array_keys( $options ) );
263
+ if ( $to_delete ) {
264
+ foreach ( $to_delete as $name ) {
265
+ unset( $options[ $name ] );
266
+ }
267
+ return update_option( self::$grouped_options[ $group ], $options );
268
+ }
269
+ return true;
270
+ }
271
+
272
+ /**
273
+ * Based on the service id and optional instance, generates the option name
274
+ *
275
+ * @param $name
276
+ * @param $service_id
277
+ * @param $service_instance
278
+ *
279
+ * @return string|bool
280
+ */
281
+ private static function get_shipping_method_option_name( $name, $service_id, $service_instance = false ) {
282
+ if ( ! in_array( $name, self::get_option_names( 'shipping_method' ) ) ) {
283
+ return false;
284
+ }
285
+
286
+ if ( ! $service_instance ) {
287
+ return 'woocommerce_' . $service_id . '_' . $name;
288
+ }
289
+
290
+ return 'woocommerce_' . $service_id . '_' . $service_instance . '_' . $name;
291
+ }
292
+
293
+ /**
294
+ * Is the option name valid?
295
+ *
296
+ * @param string $name The name of the option
297
+ * @param string $group The name of the group that the option is in. Defaults to compact.
298
+ *
299
+ * @return bool Is the option name valid?
300
+ */
301
+ private static function is_valid( $name, $group = 'non_compact' ) {
302
+ $group_keys = array_keys( self::$grouped_options );
303
+
304
+ if ( is_array( $name ) ) {
305
+ $compact_names = array();
306
+ foreach ( $group_keys as $_group ) {
307
+ $compact_names = array_merge( $compact_names, self::get_option_names( $_group ) );
308
+ }
309
+ $result = array_diff( $name, self::get_option_names( 'non_compact' ), $compact_names );
310
+ return empty( $result );
311
+ }
312
+
313
+ if ( is_null( $group ) || 'non_compact' === $group ) {
314
+ if ( in_array( $name, self::get_option_names( $group ) ) ) {
315
+ return true;
316
+ }
317
+ }
318
+
319
+ foreach ( array_keys( self::$grouped_options ) as $_group ) {
320
+ if ( is_null( $group ) || $group === $_group ) {
321
+ if ( in_array( $name, self::get_option_names( $_group ) ) ) {
322
+ return true;
323
+ }
324
+ }
325
+ }
326
+ return false;
327
+ }
328
+
329
+ /**
330
+ * Deletes all options of all shipping methods
331
+ */
332
+ private static function delete_all_shipping_methods_options() {
333
+ global $wpdb;
334
+ $methods = $wpdb->get_results( "SELECT * FROM {$wpdb->prefix}woocommerce_shipping_zone_methods " );
335
+
336
+ foreach ( (array) $methods as $method ) {
337
+ self::delete_shipping_method_options( $method->method_id, $method->instance_id );
338
+ }
339
+ }
340
+ }
341
+ }
trunk/classes/class-wc-connect-payment-gateway.php ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Payment_Gateway' ) ) {
4
+
5
+ class WC_Connect_Payment_Gateway extends WC_Payment_Gateway {
6
+
7
+ public function __construct( $settings ) {
8
+
9
+ foreach ( (array) $settings as $key => $value ) {
10
+ $this->{$key} = $value;
11
+ }
12
+
13
+ $this->init_settings();
14
+
15
+ }
16
+
17
+ }
18
+
19
+ }
20
+
trunk/classes/class-wc-connect-payment-methods-store.php ADDED
@@ -0,0 +1,119 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Payment_Methods_Store' ) ) {
4
+
5
+ class WC_Connect_Payment_Methods_Store {
6
+
7
+ /**
8
+ * @var WC_Connect_Service_Settings_Store
9
+ */
10
+ protected $service_settings_store;
11
+
12
+ /**
13
+ * @var WC_Connect_API_Client
14
+ */
15
+ protected $api_client;
16
+
17
+ /**
18
+ * @var WC_Connect_Logger
19
+ */
20
+ protected $logger;
21
+
22
+ public function __construct( WC_Connect_Service_Settings_Store $service_settings_store,
23
+ WC_Connect_API_Client $api_client, WC_Connect_Logger $logger ) {
24
+
25
+ $this->service_settings_store = $service_settings_store;
26
+ $this->api_client = $api_client;
27
+ $this->logger = $logger;
28
+
29
+ }
30
+
31
+ /**
32
+ * Fetch stored payment methods from server and store in options.
33
+ *
34
+ * @return bool Were payment methods successfully retrieved?
35
+ */
36
+ public function fetch_payment_methods_from_connect_server() {
37
+
38
+ $response_body = $this->api_client->get_payment_methods();
39
+
40
+ if ( is_wp_error( $response_body ) ) {
41
+ $this->logger->log( $response_body, __FUNCTION__ );
42
+ return false;
43
+ }
44
+
45
+ $payment_methods = $this->get_payment_methods_from_response_body( $response_body );
46
+ if ( is_wp_error( $payment_methods ) ) {
47
+ $this->logger->log( $payment_methods, __FUNCTION__ );
48
+ return false;
49
+ }
50
+
51
+ // If we made it this far, it is safe to store the object
52
+ $this->update_payment_methods( $payment_methods );
53
+
54
+ $this->potentially_update_selected_payment_method_from_payment_methods( $payment_methods );
55
+ return true;
56
+ }
57
+
58
+ protected function potentially_update_selected_payment_method_from_payment_methods( $payment_methods ) {
59
+ $payment_method_ids = array();
60
+
61
+ foreach ( (array) $payment_methods as $payment_method ) {
62
+ $payment_method_id = intval( $payment_method->payment_method_id );
63
+
64
+ if ( 0 !== $payment_method_id ) {
65
+ $payment_method_ids[] = $payment_method_id;
66
+ }
67
+ }
68
+
69
+ // No payment methods at all? Clear anything we have stored
70
+ if ( 0 === count( $payment_method_ids ) ) {
71
+ $this->service_settings_store->set_selected_payment_method_id( 0 );
72
+ return;
73
+ }
74
+
75
+ // Has the stored method ID been removed, or is there only one available? Select the first available one
76
+ $selected_payment_method_id = $this->service_settings_store->get_selected_payment_method_id();
77
+ if (
78
+ ( $selected_payment_method_id || 1 === count( $payment_method_ids ) ) &&
79
+ ! in_array( $selected_payment_method_id, $payment_method_ids )
80
+ ) {
81
+ $this->service_settings_store->set_selected_payment_method_id( $payment_method_ids[ 0 ] );
82
+ }
83
+ }
84
+
85
+ public function get_payment_methods() {
86
+ return WC_Connect_Options::get_option( 'payment_methods', array() );
87
+ }
88
+
89
+ protected function update_payment_methods( $payment_methods ) {
90
+ WC_Connect_Options::update_option( 'payment_methods', $payment_methods );
91
+ }
92
+
93
+ protected function get_payment_methods_from_response_body( $response_body ) {
94
+ if ( ! is_object( $response_body ) ) {
95
+ return new WP_Error( 'payment_method_response_body_type', 'Expected but did not receive object for response body.' );
96
+ }
97
+
98
+ if ( ! property_exists( $response_body, 'payment_methods' ) ) {
99
+ return new WP_Error( 'payment_method_response_body_missing_payment_methods', 'Expected but did not receive payment_methods in response body.' );
100
+ }
101
+
102
+ $payment_methods = $response_body->payment_methods;
103
+ if ( ! is_array( $payment_methods ) ) {
104
+ return new WP_Error( 'payment_methods_type', 'Expected but did not receive array for payment_methods.' );
105
+ }
106
+
107
+ foreach ( $payment_methods as $payment_method ) {
108
+ $required_keys = array( 'payment_method_id', 'name', 'card_type', 'card_digits', 'expiry' );
109
+ foreach ( $required_keys as $required_key ) {
110
+ if ( ! property_exists( $payment_method, $required_key ) ) {
111
+ return new WP_Error( 'payment_methods_key_missing', 'Payment method is missing a required property' );
112
+ }
113
+ }
114
+ }
115
+
116
+ return $payment_methods;
117
+ }
118
+ }
119
+ }
trunk/classes/class-wc-connect-paypal-ec.php ADDED
@@ -0,0 +1,342 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( ! class_exists( 'WC_Connect_PayPal_EC' ) ) {
8
+
9
+ /**
10
+ * Integrates with WooCommerce PayPal Checkout Payment Gateway,
11
+ * modifying that plugin's behavior to facilitate authenticating requests
12
+ * not by linking an account but via the WCS server through which we proxy.
13
+ */
14
+ class WC_Connect_PayPal_EC {
15
+
16
+ /**
17
+ * @var WC_Connect_API_Client
18
+ */
19
+ private $api_client;
20
+
21
+ /**
22
+ * @var WC_Connect_Nux
23
+ */
24
+ private $nux;
25
+
26
+ /**
27
+ * Express Checkout API methods to proxy.
28
+ */
29
+ private $methods_to_proxy = array( 'SetExpressCheckout', 'GetExpressCheckoutDetails', 'DoExpressCheckoutPayment' );
30
+
31
+ public function __construct( WC_Connect_API_Client $api_client, WC_Connect_Nux $nux ) {
32
+ $this->api_client = $api_client;
33
+ $this->nux = $nux;
34
+ }
35
+
36
+ public function init() {
37
+ if ( ! function_exists( 'wc_gateway_ppec' ) ) {
38
+ return;
39
+ }
40
+
41
+ $ppec_plugin = wc_gateway_ppec();
42
+ if ( ! property_exists( $ppec_plugin, 'settings' ) || empty( $ppec_plugin->settings ) ) {
43
+ return;
44
+ }
45
+
46
+ $this->maybe_set_reroute_requests();
47
+
48
+ add_filter( 'woocommerce_paypal_express_checkout_settings', array( $this, 'adjust_form_fields' ) );
49
+ $this->initialize_settings();
50
+ $settings = $ppec_plugin->settings;
51
+
52
+ // Don't modify any PPEC plugin behavior if WCS request proxying is not enabled
53
+ if ( 'yes' !== $settings->reroute_requests ) {
54
+ return;
55
+ }
56
+
57
+ // If empty, populate Sandbox and Live API Subject values with provided email
58
+ if (
59
+ empty( $settings->sandbox_api_subject ) &&
60
+ empty( $settings->sandbox_api_username ) &&
61
+ empty( $settings->api_username )
62
+ ) {
63
+ $email = isset( $settings->email ) ? $settings->email : $settings->api_subject;
64
+ $settings->api_subject = $email;
65
+ $settings->sandbox_api_subject = $email;
66
+ $settings->save();
67
+ }
68
+
69
+ $username = $settings->get_active_api_credentials()->get_username();
70
+ $subject = $settings->get_active_api_credentials()->get_subject();
71
+
72
+ // Proceed to attach PPEC-related hooks if email address is present but credentials are missing
73
+ if ( empty( $username ) && ! empty( $subject ) ) {
74
+ add_filter( 'woocommerce_paypal_express_checkout_request_body', array( $this, 'request_body' ) );
75
+
76
+ add_filter( 'option_woocommerce_ppec_paypal_settings', array( $this, 'adjust_settings' ) );
77
+ add_filter( 'woocommerce_payment_gateway_supports', array( $this, 'ppec_supports' ), 10, 3 );
78
+
79
+ if ( 'live' === $settings->environment ) {
80
+ // If PPEC order comes in, activate prompt to connect a PayPal account
81
+ add_action( 'woocommerce_order_status_on-hold', array( $this, 'maybe_trigger_banner' ) );
82
+ add_action( 'woocommerce_payment_complete', array( $this, 'maybe_trigger_banner' ) );
83
+
84
+ // Once a payment is received, show prompt to connect a PayPal account on certain screens
85
+ add_action( 'admin_enqueue_scripts', array( $this, 'maybe_show_banner' ) );
86
+
87
+ add_filter( 'wc_services_pointer_post.php', array( $this, 'register_refund_pointer' ) );
88
+ }
89
+ add_filter( 'pre_option_wc_gateway_ppce_prompt_to_connect', '__return_empty_string' ); // Disable default PPEC notice.
90
+ }
91
+ }
92
+
93
+ /**
94
+ * Attach request proxying hook if it's an Express Checkout method
95
+ */
96
+ public function request_body( $body ) {
97
+ if ( in_array( $body['METHOD'], $this->methods_to_proxy ) ) {
98
+ add_filter( 'pre_http_request', array( $this, 'proxy_request' ), 10, 3 );
99
+ } else {
100
+ remove_filter( 'pre_http_request', array( $this, 'proxy_request' ), 10, 3 );
101
+ }
102
+ return $body;
103
+ }
104
+
105
+ /**
106
+ * Reroute Express Checkout requests from the PPEC extension via WCS server to pick up API credentials
107
+ */
108
+ public function proxy_request( $preempt, $r, $url ) {
109
+ if ( ! preg_match( '/paypal.com\/nvp$/', $url ) ) {
110
+ return $preempt;
111
+ }
112
+
113
+ $settings = wc_gateway_ppec()->settings;
114
+ return $this->api_client->proxy_request( 'paypal/nvp/' . $settings->environment, $r );
115
+ }
116
+
117
+ /**
118
+ * Limit supported payment gateway features to payments alone
119
+ */
120
+ public function ppec_supports( $supported, $feature, $gateway ) {
121
+ return 'ppec_paypal' === $gateway->id ? 'products' === $feature : $supported;
122
+ }
123
+
124
+ /**
125
+ * Add a pointer clarifying the need to link an account before refunding payment
126
+ */
127
+ public function register_refund_pointer( $pointers ) {
128
+ $pointers[] = array(
129
+ 'id' => 'wc_services_refund_via_ppec',
130
+ 'target' => '.refund-actions > button:first-child',
131
+ 'options' => array(
132
+ 'content' => sprintf( '<h3>%s</h3><p>%s</p>',
133
+ __( 'Link a PayPal account' ,'woocommerce-services' ),
134
+ sprintf(
135
+ wp_kses(
136
+ __( 'To issue refunds via PayPal Checkout, you will need to <a href="%s">link a PayPal account</a> with the email address that received this payment.', 'woocommerce-services' ),
137
+ array( 'a' => array( 'href' => array() ) )
138
+ ),
139
+ wc_gateway_ppec()->ips->get_signup_url( wc_gateway_ppec()->settings->environment )
140
+ )
141
+ ),
142
+ 'position' => array( 'edge' => 'bottom', 'align' => 'top' ),
143
+ ),
144
+ 'delayed_opening' => array(
145
+ 'show_button' => '.refund-items',
146
+ 'hide_button' => '.cancel-action',
147
+ 'animating_container' => '.wc-order-refund-items',
148
+ 'delegation_container' => '#woocommerce-order-items',
149
+ ),
150
+ );
151
+
152
+ return $pointers;
153
+ }
154
+
155
+ /**
156
+ * Trigger banner to appear based on order paid with PPEC
157
+ */
158
+ public function maybe_trigger_banner( $order_id ) {
159
+ $order = wc_get_order( $order_id );
160
+ $payment_method = WC_Connect_Compatibility::instance()->get_payment_method( $order );
161
+
162
+ if ( 'ppec_paypal' === $payment_method ) {
163
+ WC_Connect_Options::update_option( 'banner_ppec', 'yes' );
164
+ }
165
+ }
166
+
167
+ /**
168
+ * Show banner if it has been triggered and if this screen is an appropriate place for it
169
+ */
170
+ public function maybe_show_banner() {
171
+ if ( 'yes' !== WC_Connect_Options::get_option( 'banner_ppec', null ) ) {
172
+ return;
173
+ }
174
+
175
+ $screen = get_current_screen();
176
+
177
+ if ( // Display if on any of these admin pages.
178
+ ( // Orders list.
179
+ 'shop_order' === $screen->post_type
180
+ && 'edit' === $screen->base
181
+ )
182
+ || ( // Edit order page.
183
+ 'shop_order' === $screen->post_type
184
+ && 'post' === $screen->base
185
+ && 'ppec_paypal' === WC_Connect_Compatibility::instance()->get_payment_method( wc_get_order() )
186
+ )
187
+ || ( // WooCommerce » Settings » Payments.
188
+ 'woocommerce_page_wc-settings' === $screen->base
189
+ && isset( $_GET['tab'] ) && 'checkout' === $_GET['tab']
190
+ )
191
+ || ( // WooCommerce » Extensions » Payments.
192
+ 'woocommerce_page_wc-addons' === $screen->base
193
+ && isset( $_GET['section'] ) && 'payment-gateways' === $_GET['section']
194
+ )
195
+ ) {
196
+ wp_enqueue_style( 'wc_connect_banner' );
197
+ add_action( 'admin_notices', array( $this, 'banner' ) );
198
+ }
199
+ }
200
+
201
+ /**
202
+ * Show a NUX banner prompting the merchant to link a PayPal account
203
+ */
204
+ public function banner() {
205
+ $this->nux->show_nux_banner( array(
206
+ 'title' => __( 'Link your PayPal account', 'woocommerce-services' ),
207
+ 'description' => esc_html( __( 'Link a new or existing PayPal account to make sure future orders are marked “Processing” instead of “On hold”, and so refunds can be issued without leaving WooCommerce.', 'woocommerce-services' ) ),
208
+ 'button_text' => __( 'Link account', 'woocommerce-services' ),
209
+ 'button_link' => wc_gateway_ppec()->ips->get_signup_url( 'live' ),
210
+ 'image_url' => plugins_url( 'images/cashier.svg', dirname( __FILE__ ) ),
211
+ 'should_show_jp' => false,
212
+ 'dismissible_id' => 'ppec',
213
+ ) );
214
+ }
215
+
216
+ /**
217
+ * Initialize PPEC settings to their default values
218
+ */
219
+ public function initialize_settings() {
220
+ $settings = get_option( 'woocommerce_ppec_paypal_settings', array() );
221
+
222
+ if ( ! isset( $settings['reroute_requests'] ) ) {
223
+ $settings['reroute_requests'] = 'no';
224
+ } elseif ( 'no' === $settings['reroute_requests'] ) {
225
+ return;
226
+ } elseif ( ! isset( $settings['button_size'] ) ) { // Check if settings are initialized, represented by button_size as its absence would be first to affect the customer
227
+ $payment_gateways = WC()->payment_gateways->payment_gateways();
228
+ $gateway = $payment_gateways['ppec_paypal'];
229
+
230
+ foreach ( $gateway->form_fields as $key => $form_field ) {
231
+ if ( ! isset( $settings[ $key ] ) && isset( $form_field['default'] ) ) {
232
+ $settings[ $key ] = $form_field['default'];
233
+ }
234
+ }
235
+ }
236
+
237
+ update_option( 'woocommerce_ppec_paypal_settings', $settings );
238
+ wc_gateway_ppec()->settings->load( true );
239
+ }
240
+
241
+ /**
242
+ * Force setting values that will work when proxying requests
243
+ */
244
+ public function adjust_settings( $settings ) {
245
+ $settings['paymentaction'] = 'sale';
246
+ return $settings;
247
+ }
248
+
249
+ /**
250
+ * Modify PPEC settings form to include a toggle (and other accommodations) for WCS request proxying
251
+ */
252
+ public function adjust_form_fields( $form_fields ) {
253
+ $settings = wc_gateway_ppec()->settings;
254
+
255
+ // Modify form fields and descriptions depending on whether WCS request proxying is enabled
256
+ if ( 'yes' === $settings->reroute_requests ) {
257
+ $form_fields = $this->adjust_api_subject_form_field( $form_fields );
258
+
259
+ // Prevent user from changing Payment Action away from "Sale", the only option for which payments will work
260
+ $form_fields['paymentaction']['disabled'] = true;
261
+ $form_fields['paymentaction']['description'] = sprintf( __( '%s (Note that "authorizing payment only" requires linking a PayPal account.)', 'woocommerce-services' ), $form_fields['paymentaction']['description'] );
262
+
263
+ // Communicate WCS proxying and provide option to disable
264
+ $reset_link = add_query_arg(
265
+ array( 'reroute_requests' => 'no', 'nonce' => wp_create_nonce( 'reroute_requests' ) ),
266
+ wc_gateway_ppec()->get_admin_setting_link()
267
+ );
268
+ $api_creds_template = __( 'Payments will be authenticated by WooCommerce Services and directed to the following email address. To disable this feature and link a PayPal account, <a href="%s">click here</a>.', 'woocommerce-services' );
269
+ if ( empty( $settings->api_username ) ) {
270
+ $api_creds_text = sprintf( $api_creds_template, add_query_arg( 'environment', 'live', $reset_link ) );
271
+ $form_fields['api_credentials']['description'] = $api_creds_text;
272
+ unset( $form_fields['api_username'], $form_fields['api_password'], $form_fields['api_signature'], $form_fields['api_certificate'] );
273
+ }
274
+ if ( empty( $settings->sandbox_api_username ) ) {
275
+ $api_creds_text = sprintf( $api_creds_template, add_query_arg( 'environment', 'sandbox', $reset_link ) );
276
+ $form_fields['sandbox_api_credentials']['description'] = $api_creds_text;
277
+ unset( $form_fields['sandbox_api_username'], $form_fields['sandbox_api_password'], $form_fields['sandbox_api_signature'], $form_fields['sandbox_api_certificate'] );
278
+ }
279
+
280
+ } else {
281
+ // Provide option to enable request proxying
282
+ $reset_link = add_query_arg(
283
+ array( 'reroute_requests' => 'yes', 'nonce' => wp_create_nonce( 'reroute_requests' ) ),
284
+ wc_gateway_ppec()->get_admin_setting_link()
285
+ );
286
+ $api_creds_template = __( 'To authenticate payments with WooCommerce Services, <a href="%s">click here</a>.', 'woocommerce-services' );
287
+ if ( empty( $settings->api_username ) ) {
288
+ $api_creds_text = sprintf( $api_creds_template, add_query_arg( 'environment', 'live', $reset_link ) );
289
+ $form_fields['api_credentials']['description'] .= '<br /><br />' . $api_creds_text;
290
+ }
291
+ if ( empty( $settings->sandbox_api_username ) ) {
292
+ $api_creds_text = sprintf( $api_creds_template, add_query_arg( 'environment', 'sandbox', $reset_link ) );
293
+ $form_fields['sandbox_api_credentials']['description'] .= '<br /><br />' . $api_creds_text;
294
+ }
295
+ }
296
+
297
+ return $form_fields;
298
+ }
299
+
300
+ /**
301
+ * Present the "API Subject" setting in a way that's simpler, more comprehensible, and more appropriate to the way it's being used
302
+ */
303
+ public function adjust_api_subject_form_field( $form_fields ) {
304
+ $api_subject_title = __( 'Payment Email', 'woocommerce-services' );
305
+ $form_fields['api_subject']['title'] = $api_subject_title;
306
+ $form_fields['sandbox_api_subject']['title'] = $api_subject_title;
307
+
308
+ $api_subject_description = __( 'Enter your email address at which to accept payments. You\'ll need to link your own account in order to perform anything other than "sale" transactions.', 'woocommerce-services' );
309
+ $form_fields['api_subject']['description'] = $api_subject_description;
310
+ $form_fields['sandbox_api_subject']['description'] = $api_subject_description;
311
+
312
+ $api_subject_placeholder = __( 'Required', 'woocommerce-services' );
313
+ $form_fields['api_subject']['placeholder'] = $api_subject_placeholder;
314
+ $form_fields['sandbox_api_subject']['placeholder'] = $api_subject_placeholder;
315
+
316
+ return $form_fields;
317
+ }
318
+
319
+ /**
320
+ * Handle reroute_requests setting change
321
+ */
322
+ public function maybe_set_reroute_requests() {
323
+ if (
324
+ ! isset( $_GET['page'] ) || 'wc-settings' !== $_GET['page'] ||
325
+ empty( $_GET['reroute_requests'] ) ||
326
+ empty( $_GET['nonce'] ) || ! wp_verify_nonce( $_GET['nonce'], 'reroute_requests' )
327
+ ) {
328
+ return;
329
+ }
330
+
331
+ $settings = wc_gateway_ppec()->settings;
332
+ $settings->reroute_requests = 'yes' === $_GET['reroute_requests'] ? 'yes' : 'no';
333
+ if ( isset( $_GET['environment'] ) ) {
334
+ $settings->environment = 'sandbox' === $_GET['environment'] ? 'sandbox' : 'live';
335
+ }
336
+ $settings->save();
337
+
338
+ wp_safe_redirect( wc_gateway_ppec()->get_admin_setting_link() );
339
+ exit;
340
+ }
341
+ }
342
+ }
trunk/classes/class-wc-connect-privacy.php ADDED
@@ -0,0 +1,118 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( class_exists( 'WC_Connect_Privacy' ) ) {
4
+ return;
5
+ }
6
+
7
+ class WC_Connect_Privacy {
8
+ /**
9
+ * @var WC_Connect_Service_Settings_Store
10
+ */
11
+ protected $settings_store;
12
+
13
+ /**
14
+ * @var WC_Connect_API_Client
15
+ */
16
+ protected $api_client;
17
+
18
+ public function __construct( WC_Connect_Service_Settings_Store $settings_store, WC_Connect_API_Client $api_client ) {
19
+ $this->settings_store = $settings_store;
20
+ $this->api_client = $api_client;
21
+
22
+ add_action( 'admin_init', array( $this, 'add_privacy_message' ) );
23
+ add_action( 'admin_notices', array( $this, 'add_erasure_notice' ) );
24
+ add_filter( 'woocommerce_privacy_export_order_personal_data', array( $this, 'label_data_exporter' ), 10, 2 );
25
+ add_action( 'woocommerce_privacy_before_remove_order_personal_data', array( $this, 'label_data_eraser' ) );
26
+ }
27
+
28
+ /**
29
+ * Gets the privacy message to display in the admin panel
30
+ */
31
+ public function add_privacy_message() {
32
+ if ( ! function_exists( 'wp_add_privacy_policy_content' ) ) {
33
+ return;
34
+ }
35
+
36
+ $title = __( 'WooCommerce Services', 'woocommerce-services' );
37
+ $content = wpautop(
38
+ sprintf(
39
+ wp_kses(
40
+ __( 'By using this extension, you may be storing personal data or sharing data with external services. <a href="%s" target="_blank">Learn more about how this works, including what you may want to include in your privacy policy.</a>', 'woocommerce-services' ),
41
+ array( 'a' => array( 'href' => array(), 'target' => array() ) )
42
+ ),
43
+ 'https://jetpack.com/support/for-your-privacy-policy/#woocommerce-services'
44
+ )
45
+ );
46
+
47
+ wp_add_privacy_policy_content( $title, $content );
48
+ }
49
+
50
+ /**
51
+ * If WooCommerce order data erasure is enabled, display a warning on the erasure page
52
+ */
53
+ public function add_erasure_notice() {
54
+ $screen = get_current_screen();
55
+ if ( 'tools_page_remove_personal_data' !== $screen->id ) {
56
+ return;
57
+ }
58
+
59
+ $erasure_enabled = wc_string_to_bool( get_option( 'woocommerce_erasure_request_removes_order_data', 'no' ) );
60
+ if ( ! $erasure_enabled ) {
61
+ return;
62
+ }
63
+
64
+ ?>
65
+ <div class="notice notice-warning" style="position: relative;">
66
+ <p><?php esc_html_e( 'Warning: Erasing personal data will cause the ability to reprint or refund WooCommerce Services shipping labels to be lost on the affected orders.', 'woocommerce-services' ); ?></p>
67
+ </div>
68
+ <?php
69
+ }
70
+
71
+ /**
72
+ * Filter for woocommerce_privacy_export_order_personal_data that adds WCS personal data to the exported orders
73
+ * @param array $personal_data
74
+ * @param object $order
75
+ * @return array
76
+ */
77
+ public function label_data_exporter( $personal_data, $order ) {
78
+ $order_id = $order->get_id();
79
+ $labels = $this->settings_store->get_label_order_meta_data( $order_id );
80
+
81
+ foreach ( $labels as $label ) {
82
+ if ( empty( $label['tracking'] ) ) {
83
+ continue;
84
+ }
85
+ $personal_data[] = array(
86
+ 'name' => __( 'Shipping label service', 'woocommerce-services' ),
87
+ 'value' => $label['service_name'],
88
+ );
89
+ $personal_data[] = array(
90
+ 'name' => __( 'Shipping label tracking number', 'woocommerce-services' ),
91
+ 'value' => $label['tracking'],
92
+ );
93
+ }
94
+
95
+ return $personal_data;
96
+ }
97
+
98
+ /**
99
+ * Hooks into woocommerce_privacy_before_remove_order_personal_data to remove WCS personal data from orders
100
+ * @param object $order
101
+ */
102
+ public function label_data_eraser( $order ) {
103
+ $order_id = $order->get_id();
104
+ $labels = $this->settings_store->get_label_order_meta_data( $order_id );
105
+ if ( empty( $labels ) ) {
106
+ return;
107
+ }
108
+
109
+ foreach ( $labels as $label_idx => $label ) {
110
+ $labels[ $label_idx ]['tracking'] = '';
111
+ $labels[ $label_idx ]['status'] = 'ANONYMIZED';
112
+ }
113
+
114
+ $this->api_client->anonymize_order( $order_id );
115
+
116
+ update_post_meta( $order_id, 'wc_connect_labels', $labels );
117
+ }
118
+ }
trunk/classes/class-wc-connect-service-schemas-store.php ADDED
@@ -0,0 +1,250 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Service_Schemas_Store' ) ) {
4
+
5
+ class WC_Connect_Service_Schemas_Store {
6
+
7
+ /**
8
+ * @var WC_Connect_API_Client
9
+ */
10
+ protected $api_client;
11
+
12
+ /**
13
+ * @var WC_Connect_Logger
14
+ */
15
+ protected $logger;
16
+
17
+ public function __construct( WC_Connect_API_Client $api_client, WC_Connect_Logger $logger ) {
18
+
19
+ $this->api_client = $api_client;
20
+ $this->logger = $logger;
21
+
22
+ }
23
+
24
+ public function fetch_service_schemas_from_connect_server() {
25
+
26
+ $response_body = $this->api_client->get_service_schemas();
27
+
28
+ if ( is_wp_error( $response_body ) ) {
29
+ $this->logger->log( $response_body, __FUNCTION__ );
30
+ return false;
31
+ }
32
+
33
+ $this->logger->log( 'Successfully loaded service schemas from server response.', __FUNCTION__ );
34
+ $this->update_last_fetch_timestamp();
35
+ $this->maybe_update_heartbeat();
36
+
37
+ $old_schemas = $this->get_service_schemas();
38
+ if ( $old_schemas == $response_body ) {
39
+ //schemas weren't changed, but were fetched without problems
40
+ return true;
41
+ }
42
+
43
+ // If we made it this far, it is safe to store the object
44
+ return $this->update_service_schemas( $response_body );
45
+ }
46
+
47
+ public function get_service_schemas() {
48
+ return WC_Connect_Options::get_option( 'services', null );
49
+ }
50
+
51
+ protected function update_service_schemas( $service_schemas ) {
52
+ return WC_Connect_Options::update_option( 'services', $service_schemas );
53
+ }
54
+
55
+ public function get_last_fetch_timestamp() {
56
+ return WC_Connect_Options::get_option( 'services_last_update', null );
57
+ }
58
+
59
+ protected function update_last_fetch_timestamp() {
60
+ WC_Connect_Options::update_option( 'services_last_update', time() );
61
+ }
62
+
63
+ protected function maybe_update_heartbeat() {
64
+ $last_heartbeat = WC_Connect_Options::get_option( 'last_heartbeat' );
65
+ $now = time();
66
+
67
+ if ( ! $last_heartbeat ) {
68
+ $should_update = true;
69
+ } else {
70
+ $last_heartbeat = absint( $last_heartbeat );
71
+ if ( $last_heartbeat > $now ) {
72
+ // last heartbeat in the future? wacky
73
+ $should_update = true;
74
+ } else {
75
+ $elapsed = $now - $last_heartbeat;
76
+ $should_update = $elapsed > DAY_IN_SECONDS;
77
+ }
78
+ }
79
+
80
+ if ( $should_update ) {
81
+ WC_Connect_Options::update_option( 'last_heartbeat', $now );
82
+ }
83
+ }
84
+
85
+ /**
86
+ * Returns all service ids of a specific type (e.g. shipping)
87
+ *
88
+ * @param string $type The type of services to return
89
+ *
90
+ * @return array An array of that type's service ids, or an empty array if no such type is known
91
+ */
92
+ public function get_all_service_ids_of_type( $type ) {
93
+
94
+ if ( empty( $type ) ) {
95
+ return array();
96
+ }
97
+
98
+ $service_schemas = $this->get_service_schemas();
99
+ if ( ! is_object( $service_schemas ) || ! property_exists( $service_schemas, $type ) || ! is_array( $service_schemas->$type ) ) {
100
+ return array();
101
+ }
102
+
103
+ $service_schema_ids = array();
104
+ foreach ( $service_schemas->$type as $service_schema ) {
105
+ $service_schema_ids[] = $service_schema->id;
106
+ }
107
+
108
+ return $service_schema_ids;
109
+ }
110
+
111
+ /**
112
+ * Returns all shipping method ids
113
+ *
114
+ * @return array|bool An array of supported shipping method ids or false if schema does not support method_id
115
+ */
116
+ public function get_all_shipping_method_ids() {
117
+ $shipping_method_ids = array();
118
+ $service_schemas = $this->get_service_schemas();
119
+ if ( ! is_object( $service_schemas ) || ! property_exists( $service_schemas, 'shipping' ) || ! is_array( $service_schemas->shipping ) ) {
120
+ return $shipping_method_ids;
121
+ }
122
+
123
+ foreach ( $service_schemas->shipping as $service_schema ) {
124
+ if ( ! property_exists( $service_schema, 'method_id' ) ) {
125
+ continue;
126
+ }
127
+
128
+ $shipping_method_ids[] = $service_schema->method_id;
129
+ }
130
+
131
+ return $shipping_method_ids;
132
+ }
133
+
134
+ /**
135
+ * Returns a particular service's schema given its id
136
+ *
137
+ * @param string $service_id The service id for which to return the schema
138
+ *
139
+ * @return object|null The service schema or null if no such id was found
140
+ */
141
+ public function get_service_schema_by_id( $service_id ) {
142
+ $service_schemas = $this->get_service_schemas();
143
+ if ( ! is_object( $service_schemas ) ) {
144
+ return null;
145
+ }
146
+
147
+ foreach ( $service_schemas as $service_type => $service_type_service_schemas ) {
148
+ $matches = wp_filter_object_list( $service_type_service_schemas, array( 'id' => $service_id ) );
149
+ if ( $matches ) {
150
+ return array_shift( $matches );
151
+ }
152
+ }
153
+
154
+ return null;
155
+ }
156
+
157
+ /**
158
+ * Returns a particular service's schema given its method_id
159
+ *
160
+ * @param $method_id
161
+ *
162
+ * @return object|null The service schema or null if no such id was found
163
+ */
164
+ public function get_service_schema_by_method_id( $method_id ) {
165
+ $service_schemas = $this->get_service_schemas();
166
+ if ( ! is_object( $service_schemas ) ) {
167
+ return null;
168
+ }
169
+
170
+ foreach ( $service_schemas as $service_type => $service_type_service_schemas ) {
171
+ $matches = wp_filter_object_list( $service_type_service_schemas, array( 'method_id' => $method_id ) );
172
+ if ( $matches ) {
173
+ return array_shift( $matches );
174
+ }
175
+ }
176
+
177
+ return null;
178
+ }
179
+
180
+ /**
181
+ * Returns a service's schema given its shipping zone instance
182
+ *
183
+ * @param string $instance_id The shipping zone instance id for which to return the schema
184
+ *
185
+ * @return object|null The service schema or null if no such instance was found
186
+ */
187
+ public function get_service_schema_by_instance_id( $instance_id ) {
188
+ global $wpdb;
189
+ $method_id = $wpdb->get_var(
190
+ $wpdb->prepare(
191
+ "SELECT method_id FROM {$wpdb->prefix}woocommerce_shipping_zone_methods WHERE instance_id = %d;",
192
+ $instance_id
193
+ )
194
+ );
195
+
196
+ return $this->get_service_schema_by_method_id( $method_id );
197
+ }
198
+
199
+ /**
200
+ * Returns a service's schema given an id or shipping zone instance.
201
+ *
202
+ * @param string $id_or_instance_id String ID or numeric instance ID.
203
+ * @return object|null Service schema on success, null on failure
204
+ */
205
+ public function get_service_schema_by_id_or_instance_id( $id_or_instance_id ) {
206
+
207
+ if ( is_numeric( $id_or_instance_id ) ) {
208
+ return $this->get_service_schema_by_instance_id( $id_or_instance_id );
209
+ }
210
+
211
+ if ( ! empty( $id_or_instance_id ) ) {
212
+ return $this->get_service_schema_by_method_id( $id_or_instance_id );
213
+ }
214
+
215
+ return null;
216
+ }
217
+
218
+ /**
219
+ * Returns packages schema
220
+ *
221
+ * @return object|null Packages schema on success, null on failure
222
+ */
223
+ public function get_packages_schema() {
224
+ $service_schemas = $this->get_service_schemas();
225
+ if ( ! is_object( $service_schemas ) || ! property_exists( $service_schemas, 'boxes' ) ) {
226
+ return null;
227
+ }
228
+
229
+ return $service_schemas->boxes;
230
+ }
231
+
232
+ public function get_predefined_packages_schema() {
233
+ $service_schemas = $this->get_service_schemas();
234
+ if ( ! is_object( $service_schemas ) ) {
235
+ return null;
236
+ }
237
+
238
+ $predefined_packages = array();
239
+ foreach( $service_schemas->shipping as $service_schema ) {
240
+ if ( ! isset( $service_schema->packages ) ) {
241
+ continue;
242
+ }
243
+
244
+ $predefined_packages[ $service_schema->id ] = $service_schema->packages;
245
+ }
246
+
247
+ return $predefined_packages;
248
+ }
249
+ }
250
+ }
trunk/classes/class-wc-connect-service-schemas-validator.php ADDED
@@ -0,0 +1,195 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Service_Schemas_Validator' ) ) {
4
+
5
+ class WC_Connect_Service_Schemas_Validator {
6
+
7
+ /**
8
+ * Validates the overall passed services object (all service types and all services therein)
9
+ *
10
+ * @param object $services
11
+ *
12
+ * @return WP_Error|true
13
+ */
14
+ public function validate_service_schemas( $service_schemas ) {
15
+
16
+ if ( ! is_object( $service_schemas ) ) {
17
+ return new WP_Error(
18
+ 'outermost_container_not_object',
19
+ 'Malformed service schemas. Outermost container is not an object.'
20
+ );
21
+ }
22
+
23
+ if ( ! isset( $service_schemas->shipping ) || ! is_array( $service_schemas->shipping ) ) {
24
+ return new WP_Error(
25
+ 'service_type_not_ref_array',
26
+ 'Malformed service schemas. \'shipping\' does not reference an array.'
27
+ );
28
+ }
29
+
30
+ $service_counter = 0;
31
+ foreach ( $service_schemas->shipping as $service_schema ) {
32
+ if ( ! is_object( $service_schema ) ) {
33
+ return new WP_Error(
34
+ 'service_not_ref_object',
35
+ sprintf(
36
+ 'Malformed service schema. Service type \'shipping\' [%d] does not reference an object.',
37
+ $service_counter
38
+ )
39
+ );
40
+ }
41
+
42
+ $result = $this->validate_service_schema( 'shipping', $service_counter, $service_schema );
43
+ if ( is_wp_error( $result ) ) {
44
+ return $result;
45
+ }
46
+
47
+ $service_counter ++;
48
+ }
49
+
50
+ if ( ! isset( $service_schemas->boxes ) || ! is_object( $service_schemas->boxes ) ) {
51
+ return new WP_Error(
52
+ 'boxes_not_object',
53
+ 'Malformed service schemas. \'boxes\' is not an object.'
54
+ );
55
+ }
56
+
57
+ return true;
58
+ }
59
+
60
+ /**
61
+ * Validates a particular service schema, especially the parts of the service that WC relies
62
+ * on like id, method_title, method_description, etc
63
+ *
64
+ * @param string $service_type
65
+ * @param integer $service_counter
66
+ * @param object $service
67
+ *
68
+ * @return WP_Error|true
69
+ */
70
+ protected function validate_service_schema( $service_type, $service_counter, $service_schema ) {
71
+ $required_properties = array(
72
+ 'id' => 'string',
73
+ 'method_description' => 'string',
74
+ 'method_title' => 'string',
75
+ 'service_settings' => 'object',
76
+ 'form_layout' => 'array'
77
+ );
78
+
79
+ foreach ( $required_properties as $required_property => $required_property_type ) {
80
+ if ( ! property_exists( $service_schema, $required_property ) ) {
81
+ return new WP_Error(
82
+ 'required_service_property_missing',
83
+ sprintf(
84
+ 'Malformed service schema. Service type \'%s\' [%d] does not include a required \'%s\' property.',
85
+ $service_type,
86
+ $service_counter,
87
+ $required_property
88
+ )
89
+ );
90
+ }
91
+
92
+ $property_type = gettype( $service_schema->$required_property );
93
+ if ( $required_property_type !== $property_type ) {
94
+ return new WP_Error(
95
+ 'required_service_property_wrong_type',
96
+ sprintf(
97
+ 'Malformed service schema. Service type \'%s\' [%d] property \'%s\' is a %s. Was expecting a %s.',
98
+ $service_type,
99
+ $service_counter,
100
+ $service_schema->$required_property,
101
+ $property_type,
102
+ $required_property_type
103
+ )
104
+ );
105
+ }
106
+ }
107
+
108
+ return $this->validate_service_schema_settings( $service_schema->id, $service_schema->service_settings );
109
+ }
110
+
111
+ /**
112
+ * Validates a particular service's service settings schema, especially the parts of the
113
+ * service settings that WC relies on like type, required and properties
114
+ *
115
+ * @param string $service_id
116
+ * @param object $service_settings
117
+ *
118
+ * @return WP_Error|true
119
+ */
120
+ protected function validate_service_schema_settings( $service_id, $service_settings ) {
121
+ $required_properties = array(
122
+ 'type' => 'string',
123
+ 'required' => 'array',
124
+ 'properties' => 'object'
125
+ );
126
+
127
+ foreach ( $required_properties as $required_property => $required_property_type ) {
128
+ if ( ! property_exists( $service_settings, $required_property ) ) {
129
+ return new WP_Error(
130
+ 'service_settings_missing_required_property',
131
+ sprintf(
132
+ 'The settings part of a service schema is malformed. Service \'%s\' service_settings do not include a required \'%s\' property.',
133
+ $service_id,
134
+ $required_property
135
+ )
136
+ );
137
+ }
138
+
139
+ $property_type = gettype( $service_settings->$required_property );
140
+ if ( $required_property_type !== $property_type ) {
141
+ return new WP_Error(
142
+ 'service_settings_property_wrong_type',
143
+ sprintf(
144
+ "The settings part of a service schema is malformed. Service '%s' service_setting property '%s' is a %s. Was expecting a %s.",
145
+ $service_id,
146
+ $required_property,
147
+ $property_type,
148
+ $required_property_type
149
+ )
150
+ );
151
+ }
152
+ }
153
+
154
+ $result = $this->validate_service_settings_required_properties( $service_id, $service_settings->properties );
155
+ if ( is_wp_error( $result ) ) {
156
+ return $result;
157
+ }
158
+
159
+ return true;
160
+ }
161
+
162
+
163
+ /**
164
+ * Validates a particular service's schema's required properties, especially the parts of the
165
+ * properties that WC relies on and title
166
+ *
167
+ * @param string $service_id
168
+ * @param object $service_settings_properties
169
+ *
170
+ * @return WP_Error|true
171
+ */
172
+ protected function validate_service_settings_required_properties( $service_id, $service_settings_properties ) {
173
+ $required_properties = array(
174
+ 'title'
175
+ );
176
+
177
+ foreach ( $required_properties as $required_property ) {
178
+ if ( ! property_exists( $service_settings_properties, $required_property ) ) {
179
+ return new WP_Error(
180
+ 'service_properties_missing_required_property',
181
+ sprintf(
182
+ "The properties part of a service schema is malformed. Service '%s' service_settings properties do not include a required '%s' property.",
183
+ $service_id,
184
+ $required_property
185
+ )
186
+ );
187
+ }
188
+ }
189
+
190
+ return true;
191
+ }
192
+
193
+ }
194
+
195
+ }
trunk/classes/class-wc-connect-service-settings-store.php ADDED
@@ -0,0 +1,584 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Service_Settings_Store' ) ) {
4
+
5
+ class WC_Connect_Service_Settings_Store {
6
+
7
+ /**
8
+ * @var WC_Connect_Service_Schemas_Store
9
+ */
10
+ protected $service_schemas_store;
11
+
12
+ /**
13
+ * @var WC_Connect_API_Client
14
+ */
15
+ protected $api_client;
16
+
17
+ /**
18
+ * @var WC_Connect_Logger
19
+ */
20
+ protected $logger;
21
+
22
+ public function __construct( WC_Connect_Service_Schemas_Store $service_schemas_store, WC_Connect_API_Client $api_client, WC_Connect_Logger $logger ) {
23
+ $this->service_schemas_store = $service_schemas_store;
24
+ $this->api_client = $api_client;
25
+ $this->logger = $logger;
26
+ }
27
+
28
+ /**
29
+ * Gets woocommerce store options that are useful for all connect services
30
+ *
31
+ * @return object|array
32
+ */
33
+ public function get_store_options() {
34
+ $currency_symbol = sanitize_text_field( html_entity_decode( get_woocommerce_currency_symbol() ) );
35
+ $dimension_unit = sanitize_text_field( strtolower( get_option( 'woocommerce_dimension_unit' ) ) );
36
+ $weight_unit = sanitize_text_field( strtolower( get_option( 'woocommerce_weight_unit' ) ) );
37
+ $base_location = wc_get_base_location();
38
+
39
+ return array(
40
+ 'currency_symbol' => $currency_symbol,
41
+ 'dimension_unit' => $this->translate_unit( $dimension_unit ),
42
+ 'weight_unit' => $this->translate_unit( $weight_unit ),
43
+ 'origin_country' => $base_location['country'],
44
+ );
45
+ }
46
+
47
+ /**
48
+ * Gets connect account settings (e.g. payment method)
49
+ *
50
+ * @return array
51
+ */
52
+ public function get_account_settings() {
53
+ $default = array(
54
+ 'selected_payment_method_id' => 0,
55
+ 'enabled' => true,
56
+ );
57
+
58
+ $result = WC_Connect_Options::get_option( 'account_settings', $default );
59
+ $result['paper_size'] = $this->get_preferred_paper_size();
60
+ $result = array_merge( $default, $result );
61
+
62
+ if ( ! isset( $result['email_receipts'] ) ) {
63
+ $result['email_receipts'] = true;
64
+ }
65
+
66
+ return $result;
67
+ }
68
+
69
+ /**
70
+ * Updates connect account settings (e.g. payment method)
71
+ *
72
+ * @param array $settings
73
+ *
74
+ * @return true
75
+ */
76
+ public function update_account_settings( $settings ) {
77
+ // simple validation for now
78
+ if ( ! is_array( $settings ) ) {
79
+ $this->logger->log( 'Array expected but not received', __FUNCTION__ );
80
+ return false;
81
+ }
82
+
83
+ $paper_size = $settings['paper_size'];
84
+ $this->set_preferred_paper_size( $paper_size );
85
+ unset( $settings['paper_size'] );
86
+
87
+ return WC_Connect_Options::update_option( 'account_settings', $settings );
88
+ }
89
+
90
+ public function get_selected_payment_method_id() {
91
+ $account_settings = $this->get_account_settings();
92
+ return intval( $account_settings['selected_payment_method_id'] );
93
+ }
94
+
95
+ public function set_selected_payment_method_id( $new_payment_method_id ) {
96
+ $new_payment_method_id = intval( $new_payment_method_id );
97
+ $account_settings = $this->get_account_settings();
98
+ $old_payment_method_id = intval( $account_settings['selected_payment_method_id'] );
99
+ if ( $old_payment_method_id === $new_payment_method_id ) {
100
+ return;
101
+ }
102
+ $account_settings['selected_payment_method_id'] = $new_payment_method_id;
103
+ $this->update_account_settings( $account_settings );
104
+ }
105
+
106
+ public function can_user_manage_payment_methods() {
107
+ global $current_user;
108
+ $master_user = WC_Connect_Jetpack::get_master_user();
109
+ return WC_Connect_Jetpack::is_development_mode() ||
110
+ ( is_a( $master_user, 'WP_User' ) && $current_user->ID === $master_user->ID );
111
+ }
112
+
113
+ public function get_origin_address() {
114
+ $wc_address_fields = array();
115
+ $wc_address_fields['company'] = get_bloginfo( 'name' );
116
+ $wc_address_fields['name'] = wp_get_current_user()->display_name;
117
+ $wc_address_fields['phone'] = '';
118
+
119
+ $wc_countries = WC()->countries;
120
+ // WC 3.2 introduces ability to configure a full address in the settings
121
+ // Use it for address defaults if available
122
+ if ( method_exists( $wc_countries, 'get_base_address' ) ) {
123
+ $wc_address_fields['country'] = $wc_countries->get_base_country();
124
+ $wc_address_fields['state'] = $wc_countries->get_base_state();
125
+ $wc_address_fields['address'] = $wc_countries->get_base_address();
126
+ $wc_address_fields['address_2'] = $wc_countries->get_base_address_2();
127
+ $wc_address_fields['city'] = $wc_countries->get_base_city();
128
+ $wc_address_fields['postcode'] = $wc_countries->get_base_postcode();
129
+ } else {
130
+ $base_location = wc_get_base_location();
131
+ $wc_address_fields['country'] = $base_location['country'];
132
+ $wc_address_fields['state'] = $base_location['state'];
133
+ $wc_address_fields['address'] = '';
134
+ $wc_address_fields['address_2'] = '';
135
+ $wc_address_fields['city'] = '';
136
+ $wc_address_fields['postcode'] = '';
137
+ }
138
+
139
+ $stored_address_fields = WC_Connect_Options::get_option( 'origin_address', array() );
140
+ return array_merge( $wc_address_fields, $stored_address_fields );
141
+ }
142
+
143
+ public function get_preferred_paper_size() {
144
+ $paper_size = WC_Connect_Options::get_option( 'paper_size', '' );
145
+ if ( $paper_size ) {
146
+ return $paper_size;
147
+ }
148
+ // According to https://en.wikipedia.org/wiki/Letter_(paper_size) US, Mexico, Canada and Dominican Republic
149
+ // use "Letter" size, and pretty much all the rest of the world use A4, so those are sensible defaults
150
+ $base_location = wc_get_base_location();
151
+ if ( in_array( $base_location['country'], array( 'US', 'CA', 'MX', 'DO' ), true ) ) {
152
+ return 'letter';
153
+ }
154
+ return 'a4';
155
+ }
156
+
157
+ public function set_preferred_paper_size( $size ) {
158
+ return WC_Connect_Options::update_option( 'paper_size', $size );
159
+ }
160
+
161
+ /**
162
+ * Attempts to recover faulty json string fields that might contain strings with unescaped quotes
163
+ *
164
+ * @param string $field_name
165
+ * @param string $json
166
+ *
167
+ * @return string
168
+ */
169
+ public function try_recover_invalid_json_string( $field_name, $json ) {
170
+ $regex = '/"' . $field_name . '":"(.+?)","/';
171
+ preg_match_all( $regex, $json, $match_groups );
172
+ if ( 2 === count( $match_groups ) ) {
173
+ foreach ( $match_groups[ 0 ] as $idx => $match ) {
174
+ $value = $match_groups[ 1 ][ $idx ];
175
+ $escaped_value = preg_replace( '/(?<!\\\)"/', '\\"', $value );
176
+ $json = str_replace( $match, '"' . $field_name . '":"' . $escaped_value . '","', $json );
177
+ }
178
+ }
179
+ return $json;
180
+ }
181
+
182
+ /**
183
+ * Attempts to recover faulty json string array fields that might contain strings with unescaped quotes
184
+ *
185
+ * @param string $field_name
186
+ * @param string $json
187
+ *
188
+ * @return string
189
+ */
190
+ public function try_recover_invalid_json_array( $field_name, $json ) {
191
+ $regex = '/"' . $field_name . '":\["(.+?)"\]/';
192
+ preg_match_all( $regex, $json, $match_groups );
193
+ if ( 2 === count( $match_groups ) ) {
194
+ foreach ( $match_groups[ 0 ] as $idx => $match ) {
195
+ $array = $match_groups[ 1 ][ $idx ];
196
+ $escaped_array = preg_replace( '/(?<![,\\\])"(?!,)/', '\\"', $array );
197
+ $json = str_replace( '["' . $array . '"]', '["' . $escaped_array. '"]', $json );
198
+ }
199
+ }
200
+ return $json;
201
+ }
202
+
203
+ public function try_deserialize_labels_json( $label_data ) {
204
+ //attempt to decode the JSON (legacy way of storing the labels data)
205
+ $decoded_labels = json_decode( $label_data, true );
206
+ if ( $decoded_labels ) {
207
+ return $decoded_labels;
208
+ }
209
+
210
+ $label_data = $this->try_recover_invalid_json_string( 'package_name', $label_data );
211
+ $decoded_labels = json_decode( $label_data, true );
212
+ if ( $decoded_labels ) {
213
+ return $decoded_labels;
214
+ }
215
+
216
+ $label_data = $this->try_recover_invalid_json_array( 'product_names', $label_data );
217
+ $decoded_labels = json_decode( $label_data, true );
218
+ if ( $decoded_labels ) {
219
+ return $decoded_labels;
220
+ }
221
+
222
+ return array();
223
+ }
224
+
225
+ /**
226
+ * Returns labels for the specific order ID
227
+ *
228
+ * @param $order_id
229
+ *
230
+ * @return array
231
+ */
232
+ public function get_label_order_meta_data( $order_id ) {
233
+ $label_data = get_post_meta( ( int ) $order_id, 'wc_connect_labels', true );
234
+ //return an empty array if the data doesn't exist
235
+ if ( ! $label_data ) {
236
+ return array();
237
+ }
238
+
239
+ //labels stored as an array, return
240
+ if ( is_array( $label_data ) ) {
241
+ return $label_data;
242
+ }
243
+
244
+ return $this->try_deserialize_labels_json( $label_data );
245
+ }
246
+
247
+ /**
248
+ * Updates the existing label data
249
+ *
250
+ * @param $order_id
251
+ * @param $new_label_data
252
+ *
253
+ * @return array updated label info
254
+ */
255
+ public function update_label_order_meta_data( $order_id, $new_label_data ) {
256
+ $result = $new_label_data;
257
+ $labels_data = $this->get_label_order_meta_data( $order_id );
258
+ foreach( $labels_data as $index => $label_data ) {
259
+ if ( $label_data['label_id'] === $new_label_data->label_id ) {
260
+ $result = array_merge( $label_data, (array) $new_label_data );
261
+ $labels_data[ $index ] = $result;
262
+
263
+ if ( ! isset( $label_data['tracking'] )
264
+ && isset( $result['tracking'] ) ) {
265
+ WC_Connect_Extension_Compatibility::on_new_tracking_number( $order_id, $result['carrier_id'], $result['tracking'] );
266
+ }
267
+ }
268
+ }
269
+ update_post_meta( $order_id, 'wc_connect_labels', $labels_data );
270
+ return $result;
271
+ }
272
+
273
+ /**
274
+ * Adds new labels to the order
275
+ *
276
+ * @param $order_id
277
+ * @param array $new_labels - labels to be added
278
+ */
279
+ public function add_labels_to_order( $order_id, $new_labels ) {
280
+ $labels_data = $this->get_label_order_meta_data( $order_id );
281
+ $labels_data = array_merge( $new_labels, $labels_data );
282
+ update_post_meta( $order_id, 'wc_connect_labels', $labels_data );
283
+ }
284
+
285
+ public function update_origin_address( $address ) {
286
+ return WC_Connect_Options::update_option( 'origin_address', $address );
287
+ }
288
+
289
+ public function update_destination_address( $order_id, $api_address ) {
290
+ $order = wc_get_order( $order_id );
291
+ $wc_address = $order->get_address( 'shipping' );
292
+
293
+ $new_address = array_merge( array(), ( array ) $wc_address, ( array ) $api_address );
294
+ //rename address to address_1
295
+ $new_address['address_1'] = $new_address['address'];
296
+ //remove api-specific fields
297
+ unset( $new_address['address'], $new_address['name'] );
298
+
299
+ $order->set_address( $new_address, 'shipping' );
300
+ update_post_meta( $order_id, '_wc_connect_destination_normalized', true );
301
+ }
302
+
303
+ protected function sort_services( $a, $b ) {
304
+
305
+ if ( $a->zone_order === $b->zone_order ) {
306
+ return ( $a->instance_id > $b->instance_id ) ? 1 : -1;
307
+ }
308
+
309
+ if ( is_null( $a->zone_order ) ) {
310
+ return 1;
311
+ }
312
+
313
+ if ( is_null( $b->zone_order ) ) {
314
+ return -1;
315
+ }
316
+
317
+ return ( $a->instance_id > $b->instance_id ) ? 1 : -1;
318
+
319
+ }
320
+
321
+ /**
322
+ * Returns the service type and id for each enabled WooCommerce Services service
323
+ *
324
+ * Shipping services also include instance_id and shipping zone id
325
+ *
326
+ * Note that at this time, only shipping services exist, but this method will
327
+ * return other services in the future
328
+ *
329
+ * @return array
330
+ */
331
+ public function get_enabled_services() {
332
+ $shipping_services = $this->service_schemas_store->get_all_shipping_method_ids();
333
+ if ( empty( $shipping_services ) ) {
334
+ return array();
335
+ }
336
+ return $this->get_enabled_services_by_ids( $shipping_services );
337
+ }
338
+
339
+ public function get_enabled_services_by_ids( $service_ids ) {
340
+ if ( empty( $service_ids ) ) {
341
+ return array();
342
+ }
343
+
344
+ $enabled_services = array();
345
+
346
+ // Note: We use esc_sql here instead of prepare because we are using WHERE IN
347
+ // https://codex.wordpress.org/Function_Reference/esc_sql
348
+
349
+ $escaped_list = '';
350
+ foreach ( $service_ids as $shipping_service ) {
351
+ if ( ! empty( $escaped_list ) ) {
352
+ $escaped_list .= ',';
353
+ }
354
+ $escaped_list .= "'" . esc_sql( $shipping_service ) . "'";
355
+ }
356
+
357
+ global $wpdb;
358
+ $methods = $wpdb->get_results(
359
+ "SELECT * FROM {$wpdb->prefix}woocommerce_shipping_zone_methods " .
360
+ "LEFT JOIN {$wpdb->prefix}woocommerce_shipping_zones " .
361
+ "ON {$wpdb->prefix}woocommerce_shipping_zone_methods.zone_id = {$wpdb->prefix}woocommerce_shipping_zones.zone_id " .
362
+ "WHERE method_id IN ({$escaped_list}) " .
363
+ "ORDER BY zone_order, instance_id;"
364
+ );
365
+
366
+ if ( empty( $methods ) ) {
367
+ return $enabled_services;
368
+ }
369
+
370
+ foreach ( (array) $methods as $method ) {
371
+ $service_schema = $this->service_schemas_store->get_service_schema_by_method_id( $method->method_id );
372
+ $service_settings = $this->get_service_settings( $method->method_id, $method->instance_id );
373
+ if ( is_object( $service_settings ) && property_exists( $service_settings, 'title' ) ) {
374
+ $title = $service_settings->title;
375
+ } else if ( is_object( $service_schema ) && property_exists( $service_schema, 'method_title' ) ) {
376
+ $title = $service_schema->method_title;
377
+ } else {
378
+ $title = _x( 'Unknown', 'A service with an unknown title and unknown method_title', 'woocommerce-services' );
379
+ }
380
+ $method->service_type = 'shipping';
381
+ $method->title = $title;
382
+ $method->zone_name = empty( $method->zone_name ) ? __( 'Rest of the World', 'woocommerce-services' ) : $method->zone_name;
383
+ $enabled_services[] = $method;
384
+ }
385
+
386
+ usort( $enabled_services, array( $this, 'sort_services' ) );
387
+ return $enabled_services;
388
+ }
389
+
390
+ /**
391
+ * Checks if the shipping method ids have been migrated to the "wc_services_*" format and migrates them
392
+ */
393
+ public function migrate_legacy_services() {
394
+ if ( WC_Connect_Options::get_option( 'shipping_methods_migrated', false ) //check if the method have already been migrated
395
+ || ! $this->service_schemas_store->fetch_service_schemas_from_connect_server() ) { //ensure the latest schemas are fetched
396
+ return;
397
+ }
398
+
399
+ global $wpdb;
400
+
401
+ //old services used the id field instead of method_id
402
+ $shipping_service_ids = $this->service_schemas_store->get_all_service_ids_of_type( 'shipping' );
403
+ $legacy_services = $this->get_enabled_services_by_ids( $shipping_service_ids );
404
+
405
+ foreach ( $legacy_services as $legacy_service ) {
406
+ $service_id = $legacy_service->method_id;
407
+ $instance_id = $legacy_service->instance_id;
408
+ $service_schema = $this->service_schemas_store->get_service_schema_by_id( $service_id );
409
+ $service_settings = $this->get_service_settings( $service_id, $instance_id );
410
+ if ( ( is_array( $service_settings ) && ! $service_settings ) //check for an empty array
411
+ || ( ! is_array( $service_settings ) && ! is_object( $service_settings ) ) ) { //settings are neither an array nor an object
412
+ continue;
413
+ }
414
+
415
+ $new_method_id = $service_schema->method_id;
416
+
417
+ $wpdb->update(
418
+ "{$wpdb->prefix}woocommerce_shipping_zone_methods",
419
+ array( 'method_id' => $new_method_id ),
420
+ array( 'instance_id' => $instance_id, 'method_id' => $service_id ),
421
+ array( '%s' ),
422
+ array( '%d', '%s' ) );
423
+
424
+ //update the migrated service settings
425
+ WC_Connect_Options::update_shipping_method_option( 'form_settings', $service_settings, $new_method_id, $instance_id );
426
+ //delete the old service settings
427
+ WC_Connect_Options::delete_shipping_method_options( $service_id, $instance_id );
428
+ }
429
+
430
+ WC_Connect_Options::update_option( 'shipping_methods_migrated', true );
431
+ }
432
+
433
+ /**
434
+ * Given a service's id and optional instance, returns the settings for that
435
+ * service or an empty array
436
+ *
437
+ * @param string $service_id
438
+ * @param integer $service_instance
439
+ *
440
+ * @return object|array
441
+ */
442
+ public function get_service_settings( $service_id, $service_instance = false ) {
443
+ return WC_Connect_Options::get_shipping_method_option( 'form_settings', array(), $service_id, $service_instance );
444
+ }
445
+
446
+ /**
447
+ * Given id and possibly instance, validates the settings and, if they validate, saves them to options
448
+ *
449
+ * @return bool|WP_Error
450
+ */
451
+ public function validate_and_possibly_update_settings( $settings, $id, $instance = false ) {
452
+
453
+ // Validate instance or at least id if no instance is given
454
+ if ( ! empty( $instance ) ) {
455
+ $service_schema = $this->service_schemas_store->get_service_schema_by_instance_id( $instance );
456
+ if ( ! $service_schema ) {
457
+ return new WP_Error( 'bad_instance_id', __( 'An invalid service instance was received.', 'woocommerce-services' ) );
458
+ }
459
+ } else {
460
+ $service_schema = $this->service_schemas_store->get_service_schema_by_method_id( $id );
461
+ if ( ! $service_schema ) {
462
+ return new WP_Error( 'bad_service_id', __( 'An invalid service ID was received.', 'woocommerce-services' ) );
463
+ }
464
+ }
465
+
466
+ // Validate settings with WCC server
467
+ $response_body = $this->api_client->validate_service_settings( $service_schema->id, $settings );
468
+
469
+ if ( is_wp_error( $response_body ) ) {
470
+ // TODO - handle multiple error messages when the validation endpoint can return them
471
+ return $response_body;
472
+ }
473
+
474
+ // On success, save the settings to the database and exit
475
+ WC_Connect_Options::update_shipping_method_option( 'form_settings', $settings, $id, $instance );
476
+ // Invalidate shipping rates session cache
477
+ WC_Cache_Helper::get_transient_version( 'shipping', /* $refresh = */ true );
478
+ do_action( 'wc_connect_saved_service_settings', $id, $instance, $settings );
479
+
480
+ return true;
481
+ }
482
+
483
+ /**
484
+ * Returns a global list of packages
485
+ *
486
+ * @return array
487
+ */
488
+ public function get_packages() {
489
+ return WC_Connect_Options::get_option( 'packages', array() );
490
+ }
491
+
492
+ /**
493
+ * Updates the global list of packages
494
+ *
495
+ * @param array packages
496
+ */
497
+ public function update_packages( $packages ) {
498
+ WC_Connect_Options::update_option( 'packages', $packages );
499
+ }
500
+
501
+ /**
502
+ * Returns a global list of enabled predefined packages for all services
503
+ *
504
+ * @return array
505
+ */
506
+ public function get_predefined_packages() {
507
+ return WC_Connect_Options::get_option( 'predefined_packages', array() );
508
+ }
509
+
510
+ /**
511
+ * Returns a list of enabled predefined packages for the specified service
512
+ *
513
+ * @param $service_id
514
+ * @return array
515
+ */
516
+ public function get_predefined_packages_for_service( $service_id ) {
517
+ $packages = $this->get_predefined_packages();
518
+ if ( ! isset( $packages[ $service_id ] ) ) {
519
+ return array();
520
+ }
521
+
522
+ return $packages[ $service_id ];
523
+ }
524
+
525
+ /**
526
+ * Updates the global list of enabled predefined packages for all services
527
+ *
528
+ * @param array packages
529
+ */
530
+ public function update_predefined_packages( $packages ) {
531
+ WC_Connect_Options::update_option( 'predefined_packages', $packages );
532
+ }
533
+
534
+ public function get_package_lookup() {
535
+ $lookup = array();
536
+
537
+ $custom_packages = $this->get_packages();
538
+ foreach ( $custom_packages as $custom_package ) {
539
+ $lookup[ $custom_package['name'] ] = $custom_package;
540
+ }
541
+
542
+ $predefined_packages_schema = $this->service_schemas_store->get_predefined_packages_schema();
543
+ if ( is_null( $predefined_packages_schema ) ) {
544
+ return $lookup;
545
+ }
546
+
547
+ foreach ( $predefined_packages_schema as $service_id => $groups ) {
548
+ foreach ( $groups as $group ) {
549
+ foreach ( $group->definitions as $predefined ) {
550
+ $lookup[ $predefined->id ] = ( array ) $predefined;
551
+ }
552
+ }
553
+ }
554
+
555
+ return $lookup;
556
+ }
557
+
558
+ private function translate_unit( $value ) {
559
+ switch ( $value ) {
560
+ case 'kg':
561
+ return __('kg', 'woocommerce-services');
562
+ case 'g':
563
+ return __('g', 'woocommerce-services');
564
+ case 'lbs':
565
+ return __('lbs', 'woocommerce-services');
566
+ case 'oz':
567
+ return __('oz', 'woocommerce-services');
568
+ case 'm':
569
+ return __('m', 'woocommerce-services');
570
+ case 'cm':
571
+ return __('cm', 'woocommerce-services');
572
+ case 'mm':
573
+ return __('mm', 'woocommerce-services');
574
+ case 'in':
575
+ return __('in', 'woocommerce-services');
576
+ case 'yd':
577
+ return __('yd', 'woocommerce-services');
578
+ default:
579
+ $this->logger->log( 'Unexpected measurement unit: ' . $value, __FUNCTION__ );
580
+ return $value;
581
+ }
582
+ }
583
+ }
584
+ }
trunk/classes/class-wc-connect-settings-pages.php ADDED
@@ -0,0 +1,80 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Settings_Pages' ) ) {
4
+
5
+ class WC_Connect_Settings_Pages {
6
+ /**
7
+ * @array
8
+ */
9
+ protected $fieldsets;
10
+
11
+ public function __construct() {
12
+ $this->id = 'connect';
13
+ $this->label = _x( 'WooCommerce Services', 'The WooCommerce Services brandname', 'woocommerce-services' );
14
+
15
+ add_filter( 'woocommerce_get_sections_shipping', array( $this, 'get_sections' ), 30 );
16
+ add_action( 'woocommerce_settings_shipping', array( $this, 'output_settings_screen' ), 5 );
17
+ }
18
+
19
+ /**
20
+ * Get sections.
21
+ *
22
+ * @return array
23
+ */
24
+ public function get_sections( $shipping_tabs ) {
25
+ if ( ! is_array( $shipping_tabs ) ) {
26
+ $shipping_tabs = array();
27
+ }
28
+
29
+ $shipping_tabs[ 'woocommerce-services-settings' ] = __( 'WooCommerce Services', 'woocommerce-services' );
30
+ return $shipping_tabs;
31
+ }
32
+
33
+ /**
34
+ * Output the settings.
35
+ */
36
+ public function output_settings_screen() {
37
+ global $current_section;
38
+
39
+ if ( 'woocommerce-services-settings' !== $current_section ) {
40
+ return;
41
+ }
42
+
43
+ add_filter( 'woocommerce_get_settings_shipping', '__return_empty_array' );
44
+ $this->output_shipping_settings_screen();
45
+ }
46
+
47
+ /**
48
+ * Localizes the bootstrap, enqueues the script and styles for the settings page
49
+ */
50
+ public function output_shipping_settings_screen() {
51
+ // hiding the save button because the react container has its own
52
+ global $hide_save_button;
53
+ $hide_save_button = true;
54
+
55
+ if ( WC_Connect_Jetpack::is_development_mode() ) {
56
+ if ( WC_Connect_Jetpack::is_active() ) {
57
+ $message = __( 'Note: Jetpack is connected, but development mode is also enabled on this site. Please disable development mode.', 'woocommerce-services' );
58
+ } else {
59
+ $message = __( 'Note: Jetpack development mode is enabled on this site. This site will not be able to obtain payment methods from WooCommerce Services production servers.', 'woocommerce-services' );
60
+ }
61
+ ?>
62
+ <div class="wc-connect-admin-dev-notice">
63
+ <p>
64
+ <?php echo esc_html( $message ); ?>
65
+ </p>
66
+ </div>
67
+ <?php
68
+ }
69
+
70
+ $extra_args = array();
71
+ if ( isset( $_GET['from_order'] ) ) {
72
+ $extra_args['order_id'] = $_GET['from_order'];
73
+ $extra_args['order_href'] = get_edit_post_link( $_GET['from_order'] );
74
+ }
75
+
76
+ do_action( 'enqueue_wc_connect_script', 'wc-connect-shipping-settings', $extra_args );
77
+ }
78
+ }
79
+
80
+ }
trunk/classes/class-wc-connect-shipping-label.php ADDED
@@ -0,0 +1,408 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Shipping_Label' ) ) {
4
+
5
+ class WC_Connect_Shipping_Label {
6
+
7
+ /**
8
+ * @var WC_Connect_API_Client
9
+ */
10
+ protected $api_client;
11
+
12
+ /**
13
+ * @var WC_Connect_Service_Settings_Store
14
+ */
15
+ protected $settings_store;
16
+
17
+ /**
18
+ * @var WC_Connect_Service_Schemas_Store
19
+ */
20
+ protected $service_schemas_store;
21
+
22
+ /**
23
+ * @var WC_Connect_Payment_Methods_Store
24
+ */
25
+ protected $payment_methods_store;
26
+
27
+ /**
28
+ * @var array Supported countries by USPS, see: https://webpmt.usps.gov/pmt010.cfm
29
+ */
30
+ private $supported_countries = array( 'US', 'AS', 'PR', 'VI', 'GU', 'MP', 'UM', 'FM', 'MH' );
31
+
32
+ /**
33
+ * @var array Supported currencies
34
+ */
35
+ private $supported_currencies = array( 'USD' );
36
+
37
+ private $show_metabox = null;
38
+
39
+ public function __construct(
40
+ WC_Connect_API_Client $api_client,
41
+ WC_Connect_Service_Settings_Store $settings_store,
42
+ WC_Connect_Service_Schemas_Store $service_schemas_store
43
+ ) {
44
+ $this->api_client = $api_client;
45
+ $this->settings_store = $settings_store;
46
+ $this->service_schemas_store = $service_schemas_store;
47
+ }
48
+
49
+ public function get_item_data( WC_Order $order, $item ) {
50
+ $product = WC_Connect_Compatibility::instance()->get_item_product( $order, $item );
51
+ if ( ! $product || ! $product->needs_shipping() ) {
52
+ return null;
53
+ }
54
+ $height = 0;
55
+ $length = 0;
56
+ $weight = $product->get_weight();
57
+ $width = 0;
58
+
59
+ if ( $product->has_dimensions() ) {
60
+ $height = $product->get_height();
61
+ $length = $product->get_length();
62
+ $width = $product->get_width();
63
+ }
64
+
65
+ $product_data = array(
66
+ 'height' => (float) $height,
67
+ 'product_id' => $product->get_id(),
68
+ 'length' => (float) $length,
69
+ 'quantity' => 1,
70
+ 'weight' => (float) $weight,
71
+ 'width' => (float) $width,
72
+ 'name' => $this->get_name( $product ),
73
+ 'url' => get_edit_post_link( WC_Connect_Compatibility::instance()->get_parent_product_id( $product ), null ),
74
+ );
75
+
76
+ if ( $product->is_type( 'variation' ) ) {
77
+ $product_data['attributes'] = WC_Connect_Compatibility::instance()->get_formatted_variation( $product, true );
78
+ }
79
+
80
+ return $product_data;
81
+ }
82
+
83
+ protected function get_packaging_from_shipping_method( $shipping_method ) {
84
+ if ( ! $shipping_method || ! isset( $shipping_method['wc_connect_packages'] ) ) {
85
+ return array();
86
+ }
87
+
88
+ $packages_data = $shipping_method['wc_connect_packages'];
89
+ if ( ! $packages_data ) {
90
+ return array();
91
+ }
92
+
93
+ // WC3 retrieves metadata as non-scalar values
94
+ if ( is_array( $packages_data ) ) {
95
+ return $packages_data;
96
+ }
97
+
98
+ // WC2.6 stores non-scalar values as string, but doesn't deserialize it on retrieval
99
+ $packages = maybe_unserialize( $packages_data );
100
+ if ( is_array( $packages ) ) {
101
+ return $packages;
102
+ }
103
+
104
+ // legacy WCS stored the labels as JSON
105
+ $packages = json_decode( $packages_data, true );
106
+ if ( $packages ) {
107
+ return $packages;
108
+ }
109
+
110
+ $packages_data = $this->settings_store->try_recover_invalid_json_string( 'box_id', $packages_data );
111
+ $packages = json_decode( $packages_data, true );
112
+ if ( $packages ) {
113
+ return $packages;
114
+ }
115
+
116
+ return array();
117
+ }
118
+
119
+ protected function get_packaging_metadata( WC_Order $order ) {
120
+ $shipping_methods = $order->get_shipping_methods();
121
+ $shipping_method = reset( $shipping_methods );
122
+ $packaging = $this->get_packaging_from_shipping_method( $shipping_method );
123
+
124
+ if ( is_array( $packaging ) ) {
125
+ return array_filter( $packaging );
126
+ }
127
+
128
+ return array();
129
+ }
130
+
131
+ protected function get_name( WC_Product $product ) {
132
+ if ( $product->get_sku() ) {
133
+ $identifier = $product->get_sku();
134
+ } else {
135
+ $identifier = '#' . WC_Connect_Compatibility::instance()->get_product_id( $product );
136
+
137
+ }
138
+ return sprintf( '%s - %s', $identifier, $product->get_title() );
139
+ }
140
+
141
+ public function get_selected_packages( WC_Order $order ) {
142
+ $packages = $this->get_packaging_metadata( $order );
143
+ if ( ! $packages ) {
144
+ $items = $this->get_all_items( $order );
145
+ $weight = array_sum( wp_list_pluck( $items, 'weight' ) );
146
+
147
+ $packages = array(
148
+ 'default_box' => array(
149
+ 'id' => 'default_box',
150
+ 'box_id' => 'not_selected',
151
+ 'height' => 0,
152
+ 'length' => 0,
153
+ 'weight' => $weight,
154
+ 'width' => 0,
155
+ 'items' => $items,
156
+ ),
157
+ );
158
+ }
159
+
160
+ $formatted_packages = array();
161
+
162
+ foreach ( $packages as $package_obj ) {
163
+ $package = ( array ) $package_obj;
164
+ $package_id = $package['id'];
165
+ $formatted_packages[ $package_id ] = $package;
166
+
167
+ foreach ( $package['items'] as $item_index => $item ) {
168
+ $product_data = ( array ) $item;
169
+ $product = WC_Connect_Compatibility::instance()->get_item_product( $order, $product_data );
170
+
171
+ if ( $product ) {
172
+ $product_data['name'] = $this->get_name( $product );
173
+ $product_data['url'] = get_edit_post_link( WC_Connect_Compatibility::instance()->get_parent_product_id( $product ), null );
174
+ if ( $product->is_type( 'variation' ) ) {
175
+ $formatted = WC_Connect_Compatibility::instance()->get_formatted_variation( $product, true );
176
+ $product_data['attributes'] = $formatted;
177
+ }
178
+ $customs_info = get_post_meta( $product_data['product_id'], 'wc_connect_customs_info', true );
179
+ if ( $customs_info ) {
180
+ $product_data = array_merge( $product_data, $customs_info );
181
+ }
182
+ } else {
183
+ $product_data['name'] = WC_Connect_Compatibility::instance()->get_product_name_from_order( $product_data['product_id'], $order );
184
+ }
185
+ $product_data['value'] = WC_Connect_Compatibility::instance()->get_product_price_from_order( $product_data['product_id'], $order );
186
+ if ( ! isset( $product_data['value'] ) ) {
187
+ $product_data['value'] = 0;
188
+ }
189
+
190
+ $formatted_packages[ $package_id ]['items'][ $item_index ] = $product_data;
191
+ }
192
+ }
193
+
194
+ return $formatted_packages;
195
+ }
196
+
197
+ public function get_all_items( WC_Order $order ) {
198
+ if ( $this->get_packaging_metadata( $order ) ) {
199
+ return array();
200
+ }
201
+
202
+ $items = array();
203
+ foreach ( $order->get_items() as $item ) {
204
+ $item_data = $this->get_item_data( $order, $item );
205
+ if ( null === $item_data ) {
206
+ continue;
207
+ }
208
+
209
+ for ( $i = 0; $i < $item['qty']; $i++ ) {
210
+ $items[] = $item_data;
211
+ }
212
+ }
213
+
214
+ return $items;
215
+ }
216
+
217
+ public function get_selected_rates( WC_Order $order ) {
218
+ $shipping_methods = $order->get_shipping_methods();
219
+ $shipping_method = reset( $shipping_methods );
220
+ $packages = $this->get_packaging_from_shipping_method( $shipping_method );
221
+ $rates = array();
222
+
223
+ foreach ( $packages as $idx => $package_obj ) {
224
+ $package = ( array ) $package_obj;
225
+ // Abort if the package data is malformed
226
+ if ( ! isset( $package['id'] ) || ! isset( $package['service_id'] ) ) {
227
+ return array();
228
+ }
229
+
230
+ $rates[ $package['id'] ] = $package['service_id'];
231
+ }
232
+
233
+ return $rates;
234
+ }
235
+
236
+ protected function format_address_for_api( $address ) {
237
+ // Combine first and last name
238
+ if ( ! isset( $address['name'] ) ) {
239
+ $first_name = isset( $address['first_name'] ) ? trim( $address['first_name'] ) : '';
240
+ $last_name = isset( $address['last_name'] ) ? trim( $address['last_name'] ) : '';
241
+
242
+ $address['name'] = $first_name . ' ' . $last_name;
243
+ }
244
+
245
+ // Rename address_1 to address
246
+ if ( ! isset( $address['address'] ) && isset( $address['address_1'] ) ) {
247
+ $address['address'] = $address['address_1'];
248
+ }
249
+
250
+ // Remove now defunct keys
251
+ unset( $address['first_name'], $address['last_name'], $address['address_1'] );
252
+
253
+ return $address;
254
+ }
255
+
256
+ protected function get_origin_address() {
257
+ $origin = $this->format_address_for_api( $this->settings_store->get_origin_address() );
258
+
259
+ return $origin;
260
+ }
261
+
262
+ protected function get_destination_address( WC_Order $order ) {
263
+ $order_address = $order->get_address( 'shipping' );
264
+ $destination = $this->format_address_for_api( $order_address );
265
+
266
+ return $destination;
267
+ }
268
+
269
+ protected function get_form_data( WC_Order $order ) {
270
+ $order_id = WC_Connect_Compatibility::instance()->get_order_id( $order );
271
+ $selected_packages = $this->get_selected_packages( $order );
272
+ $is_packed = ( false !== $this->get_packaging_metadata( $order ) );
273
+ $origin = $this->get_origin_address();
274
+ $selected_rates = $this->get_selected_rates( $order );
275
+ $destination = $this->get_destination_address( $order );
276
+
277
+ if ( ! $destination['country'] ) {
278
+ $destination['country'] = $origin['country'];
279
+ }
280
+
281
+ $origin_normalized = ( bool ) WC_Connect_Options::get_option( 'origin_address', false );
282
+ $destination_normalized = ( bool ) get_post_meta( $order_id, '_wc_connect_destination_normalized', true );
283
+
284
+ $form_data = compact( 'is_packed', 'selected_packages', 'origin', 'destination', 'origin_normalized', 'destination_normalized' );
285
+
286
+ $form_data['rates'] = array(
287
+ 'selected' => (object) $selected_rates,
288
+ );
289
+
290
+ $form_data['order_id'] = $order_id;
291
+
292
+ return $form_data;
293
+ }
294
+
295
+ private function is_supported_country( $country_code ) {
296
+ return in_array( $country_code, $this->supported_countries );
297
+ }
298
+
299
+ private function is_supported_currency( $currency_code ) {
300
+ return in_array( $currency_code, $this->supported_currencies );
301
+ }
302
+
303
+ public function should_show_meta_box() {
304
+ if ( null === $this->show_metabox ) {
305
+ $this->show_metabox = $this->calculate_should_show_meta_box();
306
+ }
307
+
308
+ return $this->show_metabox;
309
+ }
310
+
311
+ private function calculate_should_show_meta_box() {
312
+ $order = wc_get_order();
313
+
314
+ if ( ! $order ) {
315
+ return false;
316
+ }
317
+
318
+ // If the order already has purchased labels, show the meta-box no matter what
319
+ if ( get_post_meta( WC_Connect_Compatibility::instance()->get_order_id( $order ), 'wc_connect_labels', true ) ) {
320
+ return true;
321
+ }
322
+
323
+ // Restrict showing the metabox to supported store currencies.
324
+ $base_currency = get_woocommerce_currency();
325
+ if ( ! $this->is_supported_currency( $base_currency ) ) {
326
+ return false;
327
+ }
328
+
329
+ $base_location = wc_get_base_location();
330
+ if ( ! $this->is_supported_country( $base_location['country'] ) ) {
331
+ return false;
332
+ }
333
+
334
+ // If the order was created using WCS checkout rates, show the meta-box regardless of the products' state
335
+ if ( $this->get_packaging_metadata( $order ) ) {
336
+ return true;
337
+ }
338
+
339
+ // At this point (no packaging data), only show if there's at least one existing and shippable product
340
+ foreach ( $order->get_items() as $item ) {
341
+ $product = WC_Connect_Compatibility::instance()->get_item_product( $order, $item );
342
+ if ( $product && $product->needs_shipping() ) {
343
+ return true;
344
+ }
345
+ }
346
+
347
+ return false;
348
+ }
349
+
350
+ public function get_label_payload( $post_order_or_id ) {
351
+ $order = wc_get_order( $post_order_or_id );
352
+ if ( ! $order ) {
353
+ return false;
354
+ }
355
+
356
+ $order_id = WC_Connect_Compatibility::instance()->get_order_id( $order );
357
+ $payload = array(
358
+ 'orderId' => $order_id,
359
+ 'paperSize' => $this->settings_store->get_preferred_paper_size(),
360
+ 'formData' => $this->get_form_data( $order ),
361
+ 'labelsData' => $this->settings_store->get_label_order_meta_data( $order_id ),
362
+ 'storeOptions' => $this->settings_store->get_store_options(),
363
+ //for backwards compatibility, still disable the country dropdown for calypso users with older plugin versions
364
+ 'canChangeCountries' => true,
365
+ );
366
+
367
+ return $payload;
368
+ }
369
+
370
+ /**
371
+ * Filter items needing shipping callback.
372
+ *
373
+ * @since 3.0.0
374
+ * @param array $item Item to check for shipping.
375
+ * @return bool
376
+ */
377
+ protected function filter_items_needing_shipping( $item ) {
378
+ $product = $item->get_product();
379
+ return $product && $product->needs_shipping();
380
+ }
381
+
382
+ /**
383
+ * Reduce items to sum their quantities.
384
+ *
385
+ * @param int $sum Current sum.
386
+ * @param array $item Item to add to sum.
387
+ * @return int
388
+ */
389
+ protected function reducer_items_quantity( $sum, $item ) {
390
+ return $sum + $item->get_quantity();
391
+ }
392
+
393
+ public function meta_box( $post, $args ) {
394
+ $order = wc_get_order( $post );
395
+ $order_id = WC_Connect_Compatibility::instance()->get_order_id( $order );
396
+ $items = array_filter( $order->get_items(), array( $this, 'filter_items_needing_shipping' ) );
397
+ $items_count = array_reduce( $items, array( $this, 'reducer_items_quantity' ), 0 );
398
+ $payload = array(
399
+ 'orderId' => $order_id,
400
+ 'context' => $args['args']['context'],
401
+ 'items' => $items_count,
402
+ );
403
+
404
+ do_action( 'enqueue_wc_connect_script', 'wc-connect-create-shipping-label', $payload );
405
+ }
406
+
407
+ }
408
+ }
trunk/classes/class-wc-connect-shipping-method.php ADDED
@@ -0,0 +1,636 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! class_exists( 'WC_Connect_Shipping_Method' ) ) {
4
+
5
+ class WC_Connect_Shipping_Method extends WC_Shipping_Method {
6
+
7
+ /**
8
+ * @var object A reference to a the fetched properties of the service
9
+ */
10
+ protected $service_schema = null;
11
+
12
+ /**
13
+ * @var WC_Connect_Service_Settings_Store
14
+ */
15
+ protected $service_settings_store;
16
+
17
+ /**
18
+ * @var WC_Connect_Logger
19
+ */
20
+ protected $logger;
21
+
22
+ /**
23
+ * @var WC_Connect_API_Client
24
+ */
25
+ protected $api_client;
26
+
27
+ public function __construct( $id_or_instance_id = null ) {
28
+ parent::__construct( $id_or_instance_id );
29
+
30
+ // If $arg looks like a number, treat it as an instance_id
31
+ // Otherwise, treat it as a (method) id (e.g. wc_connect_usps)
32
+ if ( is_numeric( $id_or_instance_id ) ) {
33
+ $this->instance_id = absint( $id_or_instance_id );
34
+ } else {
35
+ $this->instance_id = null;
36
+ }
37
+
38
+ /**
39
+ * Provide a dependency injection point for each shipping method.
40
+ *
41
+ * WooCommerce core instantiates shipping method with only a string ID
42
+ * or a numeric instance ID. We depend on more than that, so we need
43
+ * to provide a hook for our plugin to inject dependencies into each
44
+ * shipping method instance.
45
+ *
46
+ * @param WC_Connect_Shipping_Method $this
47
+ * @param int|string $id_or_instance_id
48
+ */
49
+ do_action( 'wc_connect_service_init', $this, $id_or_instance_id );
50
+
51
+ if ( ! $this->service_schema ) {
52
+ $this->log_error(
53
+ 'Error. A WC_Connect_Shipping_Method was constructed without an id or instance_id',
54
+ __FUNCTION__
55
+ );
56
+ $this->id = 'wc_connect_uninitialized_shipping_method';
57
+ $this->method_title = '';
58
+ $this->method_description = '';
59
+ $this->supports = array();
60
+ $this->title = '';
61
+ } else {
62
+ $this->id = $this->service_schema->method_id;
63
+ $this->method_title = $this->service_schema->method_title;
64
+ $this->method_description = $this->service_schema->method_description;
65
+ $this->supports = array(
66
+ 'shipping-zones',
67
+ 'instance-settings'
68
+ );
69
+
70
+ // Set title to default value
71
+ $this->title = $this->service_schema->method_title;
72
+
73
+ // Load form values from options, updating title if present
74
+ $this->init_form_settings();
75
+
76
+ // Note - we cannot hook admin_enqueue_scripts here because we need an instance id
77
+ // and this constructor is not called with an instance id until after
78
+ // admin_enqueue_scripts has already fired. This is why WC_Connect_Loader
79
+ // does it instead
80
+ }
81
+ }
82
+
83
+ public function get_service_schema() {
84
+
85
+ return $this->service_schema;
86
+
87
+ }
88
+
89
+ public function set_service_schema( $service_schema ) {
90
+
91
+ $this->service_schema = $service_schema;
92
+
93
+ }
94
+
95
+ public function get_service_settings_store() {
96
+
97
+ return $this->service_settings_store;
98
+
99
+ }
100
+
101
+ public function set_service_settings_store( $service_settings_store ) {
102
+
103
+ $this->service_settings_store = $service_settings_store;
104
+
105
+ }
106
+
107
+ public function get_logger() {
108
+
109
+ return $this->logger;
110
+
111
+ }
112
+
113
+ public function set_logger( WC_Connect_Logger $logger ) {
114
+
115
+ $this->logger = $logger;
116
+
117
+ }
118
+
119
+ public function get_api_client() {
120
+
121
+ return $this->api_client;
122
+
123
+ }
124
+
125
+ public function set_api_client( WC_Connect_API_Client $api_client ) {
126
+
127
+ $this->api_client = $api_client;
128
+
129
+ }
130
+
131
+ /**
132
+ * Logging helper.
133
+ *
134
+ * Avoids calling methods on an undefined object if no logger was
135
+ * injected during the init action in the constructor.
136
+ *
137
+ * @see WC_Connect_Logger::debug()
138
+ * @param string|WP_Error $message
139
+ * @param string $context
140
+ */
141
+ protected function log( $message, $context = '' ) {
142
+
143
+ $logger = $this->get_logger();
144
+
145
+ if ( is_a( $logger, 'WC_Connect_Logger' ) ) {
146
+
147
+ $logger->log( $message, $context );
148
+
149
+ }
150
+
151
+ }
152
+
153
+ protected function log_error( $message, $context = '' ) {
154
+ $logger = $this->get_logger();
155
+ if ( is_a( $logger, 'WC_Connect_Logger' ) ) {
156
+ $logger->error( $message, $context );
157
+ }
158
+ }
159
+
160
+ /**
161
+ * Restores any values persisted to the DB for this service instance
162
+ * and sets up title for WC core to work properly
163
+ *
164
+ */
165
+ protected function init_form_settings() {
166
+
167
+ $form_settings = $this->get_service_settings();
168
+
169
+ // We need to initialize the instance title ($this->title)
170
+ // from the settings blob
171
+ if ( property_exists( $form_settings, 'title' ) ) {
172
+ $this->title = $form_settings->title;
173
+ }
174
+
175
+ }
176
+
177
+ /**
178
+ * Returns the settings for this service (e.g. for use in the form or for
179
+ * sending to the rate request endpoint
180
+ *
181
+ * Used by WC_Connect_Loader to embed the form schema in the page for JS to consume
182
+ *
183
+ * @return object
184
+ */
185
+ public function get_service_settings() {
186
+ $service_settings = $this->service_settings_store->get_service_settings( $this->id, $this->instance_id );
187
+ if ( ! is_object( $service_settings ) ) {
188
+ $service_settings = new stdClass();
189
+ }
190
+
191
+ if ( ! property_exists( $service_settings, 'services' ) ) {
192
+ return $service_settings;
193
+ }
194
+
195
+ return $service_settings;
196
+ }
197
+
198
+ /**
199
+ * Determine if a package's destination is valid enough for a rate quote.
200
+ *
201
+ * @param array $package
202
+ * @return bool
203
+ */
204
+ public function is_valid_package_destination( $package ) {
205
+
206
+ $country = isset( $package['destination']['country'] ) ? $package['destination']['country'] : '';
207
+ $postcode = isset( $package['destination']['postcode'] ) ? $package['destination']['postcode'] : '';
208
+ $state = isset( $package['destination']['state'] ) ? $package['destination']['state'] : '';
209
+
210
+ // Ensure that Country is specified
211
+ if ( empty( $country ) ) {
212
+ $this->debug( 'Skipping rate calculation - missing country', 'error' );
213
+ return false;
214
+ }
215
+
216
+ // Validate Postcode
217
+ if ( ! WC_Validation::is_postcode( $postcode, $country ) ) {
218
+ $this->debug( 'Skipping rate calculation - invalid postcode', 'error' );
219
+ return false;
220
+ }
221
+
222
+ // Validate State
223
+ $valid_states = WC()->countries->get_states( $country );
224
+
225
+ if ( $valid_states && ! array_key_exists( $state, $valid_states ) ) {
226
+ $this->debug( 'Skipping rate calculation - invalid/unsupported state', 'error' );
227
+ return false;
228
+ }
229
+
230
+ return true;
231
+
232
+ }
233
+
234
+ private function lookup_product( $package, $product_id ) {
235
+ foreach ( $package[ 'contents' ] as $item ) {
236
+ if ( $item[ 'product_id' ] === $product_id || $item[ 'variation_id' ] === $product_id ) {
237
+ return $item[ 'data' ];
238
+ }
239
+ }
240
+
241
+ return false;
242
+ }
243
+
244
+ private function filter_preset_boxes( $preset_id ) {
245
+ return is_string( $preset_id );
246
+ }
247
+
248
+ private function check_and_handle_response_error( $response_body, $service_settings ) {
249
+ if ( is_wp_error( $response_body ) ) {
250
+ $this->debug(
251
+ sprintf(
252
+ 'Request failed: %s',
253
+ $response_body->get_error_message()
254
+ ),
255
+ 'error'
256
+ );
257
+ $this->log_error(
258
+ sprintf(
259
+ 'Error. Unable to get shipping rate(s) for %s instance id %d.',
260
+ $this->id,
261
+ $this->instance_id
262
+ ),
263
+ __FUNCTION__
264
+ );
265
+
266
+ $this->set_last_request_failed();
267
+
268
+ $this->log_error( $response_body, __FUNCTION__ );
269
+ $this->add_fallback_rate( $service_settings );
270
+ return true;
271
+ }
272
+
273
+ if ( ! property_exists( $response_body, 'rates' ) ) {
274
+ $this->debug( 'Response is missing `rates` property', 'error' );
275
+ $this->set_last_request_failed();
276
+ $this->add_fallback_rate( $service_settings );
277
+ return true;
278
+ }
279
+
280
+ return false;
281
+ }
282
+
283
+ private function add_fallback_rate( $service_settings ) {
284
+ if ( ! property_exists( $service_settings, 'fallback_rate' ) || 0 >= $service_settings->fallback_rate ) {
285
+ return;
286
+ }
287
+
288
+ $this->debug( 'No rates found, adding fallback.', 'error' );
289
+
290
+ $rate_to_add = array(
291
+ 'id' => self::format_rate_id( 'fallback', $this->id, 0 ),
292
+ 'label' => self::format_rate_title( $this->service_schema->carrier_name ),
293
+ 'cost' => $service_settings->fallback_rate,
294
+ );
295
+
296
+ $this->add_rate( $rate_to_add );
297
+ }
298
+
299
+ public function calculate_shipping( $package = array() ) {
300
+ if ( ! WC_Connect_Functions::should_send_cart_api_request() ) {
301
+ return;
302
+ }
303
+
304
+ $this->debug( sprintf(
305
+ 'WooCommerce Services debug mode is on - to hide these messages, turn debug mode off in the <a href="%s" style="text-decoration: underline;">settings</a>.',
306
+ admin_url( 'admin.php?page=wc-status&tab=connect' )
307
+ ) );
308
+
309
+ if ( ! $this->is_valid_package_destination( $package ) ) {
310
+ return;
311
+ }
312
+
313
+ $service_settings = $this->get_service_settings();
314
+ $settings_keys = get_object_vars( $service_settings );
315
+
316
+ if ( empty( $settings_keys ) ) {
317
+ $this->log(
318
+ sprintf(
319
+ 'Service settings empty. Skipping %s rate request (instance id %d).',
320
+ $this->id,
321
+ $this->instance_id
322
+ ),
323
+ __FUNCTION__
324
+ );
325
+ return;
326
+ }
327
+
328
+ // TODO: Request rates for all WooCommerce Services powered methods in
329
+ // the current shipping zone to avoid each method making an independent request
330
+ $services = array(
331
+ array(
332
+ 'id' => $this->service_schema->id,
333
+ 'instance' => $this->instance_id,
334
+ 'service_settings' => $service_settings,
335
+ ),
336
+ );
337
+
338
+ $custom_boxes = $this->service_settings_store->get_packages();
339
+ $predefined_boxes = $this->service_settings_store->get_predefined_packages_for_service( $this->service_schema->id );
340
+ $predefined_boxes = array_values( array_filter( $predefined_boxes, array( $this, 'filter_preset_boxes' ) ) );
341
+
342
+ $cache_key = sprintf(
343
+ 'wcs_rates_%s',
344
+ md5( serialize( array( $services, $package, $custom_boxes, $predefined_boxes ) ) )
345
+ );
346
+ $debug_mode = 'yes' === get_option( 'woocommerce_shipping_debug_mode', 'no' );
347
+ $response_body = wp_cache_get( $cache_key );
348
+ if ( ! $debug_mode && false !== $response_body ) {
349
+ $this->debug( 'Rates response retrieved from cache' );
350
+ } else {
351
+ $response_body = $this->api_client->get_shipping_rates( $services, $package, $custom_boxes, $predefined_boxes );
352
+ if ( $this->check_and_handle_response_error( $response_body, $service_settings ) ) {
353
+ return;
354
+ }
355
+ wp_cache_set( $cache_key, $response_body, '', 3600 );
356
+ }
357
+
358
+ $instances = $response_body->rates;
359
+
360
+ foreach ( (array) $instances as $instance ) {
361
+ if ( property_exists( $instance, 'error' ) ) {
362
+ $this->log_error( $instance->error, __FUNCTION__ );
363
+ $this->set_last_request_failed();
364
+ }
365
+
366
+ if ( ! property_exists( $instance, 'rates' ) ) {
367
+ continue;
368
+ }
369
+
370
+ $packaging_lookup = $this->service_settings_store->get_package_lookup();
371
+
372
+ foreach ( (array) $instance->rates as $rate_idx => $rate ) {
373
+ $package_summaries = array();
374
+ $service_ids = array();
375
+
376
+ $dimension_unit = get_option( 'woocommerce_dimension_unit' );
377
+ $weight_unit = get_option( 'woocommerce_weight_unit' );
378
+ $measurements_format = '(%s x %s x %s ' . $dimension_unit . ', %s ' . $weight_unit . ')';
379
+
380
+ foreach ( $rate->packages as $rate_package ) {
381
+ $service_ids[] = $rate_package->service_id;
382
+
383
+ $item_product_ids = array();
384
+ $item_by_product = array();
385
+ foreach ( $rate_package->items as $package_item ) {
386
+ $item_product_ids[] = $package_item->product_id;
387
+ $item_by_product[ $package_item->product_id ] = $package_item;
388
+ }
389
+
390
+ $product_summaries = array();
391
+ $product_counts = array_count_values( $item_product_ids );
392
+ foreach ( $product_counts as $product_id => $count ) {
393
+ /** @var WC_Product $product */
394
+ $product = $this->lookup_product( $package, $product_id );
395
+ if ( $product ) {
396
+ $item_name = WC_Connect_Compatibility::instance()->get_product_name( $product );
397
+ $item = $item_by_product[ $product_id ];
398
+ $item_measurements = sprintf( $measurements_format, $item->length, $item->width, $item->height, $item->weight );
399
+ $product_summaries[] =
400
+ ( $count > 1 ? sprintf( '<em>%d x</em> ', $count ) : '' ) .
401
+ sprintf( '(ID: %d) <strong>%s</strong> %s', $product_id, esc_html( $item_name ), esc_html( $item_measurements ) );
402
+ }
403
+ }
404
+
405
+ $package_measurements = '';
406
+
407
+ if ( ! property_exists( $rate_package, 'box_id' ) ) {
408
+ $package_name = __( 'Unknown package', 'woocommerce-services' );
409
+ } else if ( 'individual' === $rate_package->box_id ) {
410
+ $package_name = __( 'Individual packaging', 'woocommerce-services' );
411
+ } else if (
412
+ isset( $packaging_lookup[ $rate_package->box_id ] ) &&
413
+ isset( $packaging_lookup[ $rate_package->box_id ]['name'] )
414
+ ) {
415
+ $package_name = $packaging_lookup[ $rate_package->box_id ]['name'];
416
+ $package_measurements = sprintf(
417
+ $measurements_format,
418
+ $rate_package->length,
419
+ $rate_package->width,
420
+ $rate_package->height,
421
+ $rate_package->weight
422
+ );
423
+ }
424
+
425
+ $package_summaries[] = sprintf( '<strong>%s</strong> %s', $package_name, $package_measurements )
426
+ . '<ul><li>' . implode( '</li><li>', $product_summaries ) . '</li></ul>';
427
+ }
428
+
429
+ $packaging_info = implode( ', ', $package_summaries );
430
+ $services_list = implode( '-', array_unique( $service_ids ) );
431
+ $box_packing_log = empty( $rate->box_packing_log ) ? array() : $rate->box_packing_log;
432
+
433
+ $rate_to_add = array(
434
+ // Make sure the rate ID is identifiable for extensions like Conditional Shipping and Payments.
435
+ // The new format looks like: `wc_services_usps:1:pri_medium_flat_box_top`.
436
+ 'id' => self::format_rate_id( $this->id, $instance->instance, $services_list ),
437
+ 'label' => self::format_rate_title( $rate->title ),
438
+ 'cost' => $rate->rate,
439
+ 'meta_data' => array(
440
+ 'wc_connect_packages' => $rate->packages,
441
+ __( 'Packaging', 'woocommerce-services' ) => $packaging_info,
442
+ 'wc_connect_packing_log' => $box_packing_log,
443
+ ),
444
+ );
445
+
446
+ if ( $this->logger->is_debug_enabled() ) {
447
+ if ( 'fallback' === $services_list ) {
448
+ // Notify the merchant when the fallback rate is added by the WCS server.
449
+ $this->debug( 'No rates found, adding fallback.', 'error' );
450
+ } else {
451
+ $rate_debug = '<strong>';
452
+ $rate_debug .= sprintf(
453
+ /* translators: 1: name of shipping service, 2: shipping rate (price) */
454
+ __( 'Received rate: %1$s (%2$s)', 'woocommerce-services' ),
455
+ $rate_to_add['label'],
456
+ wc_price( $rate->rate )
457
+ );
458
+ $rate_debug .= '</strong><ul><li>' . implode( '</li><li>', $package_summaries ) . '</li></ul>';
459
+
460
+ if ( ! empty( $box_packing_log ) ) {
461
+ $rate_debug .= '<strong>' . __( 'Packing log:', 'woocommerce-services' ) . '</strong>';
462
+ $rate_debug .= '<ul><li>' . implode( '</li><li>', array_map( 'esc_html', $box_packing_log ) ) . '</li></ul>';
463
+ }
464
+
465
+ $this->debug( $rate_debug, 'success' );
466
+ }
467
+ }
468
+
469
+ $this->add_rate( $rate_to_add );
470
+ }
471
+ }
472
+
473
+ if ( 0 === count( $this->rates ) ) {
474
+ $this->add_fallback_rate( $service_settings );
475
+ } else {
476
+ $this->set_last_request_failed( 0 );
477
+ }
478
+
479
+ $this->update_last_rate_request_timestamp();
480
+ }
481
+
482
+ public function update_last_rate_request_timestamp() {
483
+ $previous_timestamp = WC_Connect_Options::get_option( 'last_rate_request' );
484
+ if ( false === $previous_timestamp ||
485
+ ( time() - HOUR_IN_SECONDS ) > $previous_timestamp ) {
486
+ WC_Connect_Options::update_option( 'last_rate_request', time() );
487
+ }
488
+ }
489
+
490
+ public function set_last_request_failed( $timestamp = null ) {
491
+ if ( is_null( $timestamp ) ) {
492
+ $timestamp = time();
493
+ }
494
+
495
+ WC_Connect_Options::update_shipping_method_option( 'failure_timestamp', $timestamp, $this->id, $this->instance_id );
496
+ }
497
+
498
+ public function admin_options() {
499
+ // hide WP native save button on settings page
500
+ global $hide_save_button;
501
+ $hide_save_button = true;
502
+
503
+ do_action( 'wc_connect_service_admin_options', $this->id, $this->instance_id );
504
+ }
505
+
506
+ /**
507
+ * @param string $method_id
508
+ * @param int $instance_id
509
+ * @param string $service_ids
510
+ *
511
+ * @return string
512
+ */
513
+ public static function format_rate_id( $method_id, $instance_id, $service_ids ) {
514
+ return sprintf( '%s:%d:%s', $method_id, $instance_id, $service_ids );
515
+ }
516
+
517
+ public static function format_rate_title( $rate_title ) {
518
+ $formatted_title = wp_kses(
519
+ html_entity_decode( $rate_title ),
520
+ array(
521
+ 'sup' => array(),
522
+ 'del' => array(),
523
+ 'small' => array(),
524
+ 'em' => array(),
525
+ 'i' => array(),
526
+ 'strong' => array(),
527
+ )
528
+ );
529
+
530
+ return $formatted_title;
531
+ }
532
+
533
+ /**
534
+ * Log debug by printing it as notice.
535
+ *
536
+ * @param string $message Debug message.
537
+ * @param string $type Notice type.
538
+ */
539
+ public function debug( $message, $type = 'notice' ) {
540
+ if ( is_cart() || is_checkout() || isset( $_POST['update_cart'] ) ) {
541
+ $debug_message = sprintf( '%s (%s:%d)', $message, esc_html( $this->title ), $this->instance_id );
542
+
543
+ $this->logger->debug( $debug_message, $type );
544
+ }
545
+ }
546
+
547
+ /**
548
+ * Is this method available?
549
+ *
550
+ * @param array $package Package.
551
+ * @return bool
552
+ */
553
+ public function is_available( $package ) {
554
+ if ( ! parent::is_available( $package ) ) {
555
+ return false;
556
+ }
557
+
558
+ if ( ! $this->matches_package_shipping_classes( $package ) ) {
559
+ return false;
560
+ }
561
+
562
+ return true;
563
+ }
564
+
565
+ /**
566
+ * Checks whether the shipping classes of all products in a package are
567
+ * actually supported by the method. If a single product has an un-supported class,
568
+ * the whole package will not be supported by the method.
569
+ *
570
+ * @param array $package The contents of a package.
571
+ * @return bool
572
+ */
573
+ public function matches_package_shipping_classes( $package ) {
574
+ $settings = $this->get_service_settings();
575
+ $method_classes = property_exists( $settings, 'shipping_classes' )
576
+ ? $settings->shipping_classes
577
+ : array();
578
+
579
+ // No checks needed if the method is not limited to certain classes.
580
+ if ( empty( $method_classes ) ) {
581
+ return true;
582
+ }
583
+
584
+ // Go through the cart contents and check if all products are supported
585
+ foreach ( $package['contents'] as $item ) {
586
+ $shipping_class_id = $item['data']->get_shipping_class_id();
587
+
588
+ if ( in_array( $shipping_class_id, $method_classes, true ) ) {
589
+ continue;
590
+ }
591
+
592
+ if ( ! $this->logger->is_debug_enabled() ) {
593
+ return false;
594
+ }
595
+
596
+ $message = 'Skipping the "%1$s" shipping method because %2$s (%3$s) does not match the shipping classes specified in the method settings (%4$s).';
597
+
598
+ $product_class_name = 'No shipping class';
599
+ if ( $shipping_class_id ) {
600
+ $shipping_class = get_term_by( 'id', $shipping_class_id, 'product_shipping_class' );
601
+
602
+ if ( $shipping_class ) {
603
+ $product_class_name = $shipping_class->name;
604
+ }
605
+ }
606
+
607
+ $method_classes = get_terms( array(
608
+ 'taxonomy' => 'product_shipping_class',
609
+ 'hide_empty' => false,
610
+ 'include' => $method_classes,
611
+ ) );
612
+
613
+ if ( ! is_wp_error( $method_classes ) && ! empty( $method_classes ) ) {
614
+ $class_names = implode( wp_list_pluck( $method_classes, 'name' ), ', ' );
615
+ } else {
616
+ $class_names = 'No shipping classes found';
617
+ }
618
+
619
+ $message = sprintf(
620
+ $message,
621
+ $this->title,
622
+ $item['data']->get_title(),
623
+ $product_class_name,
624
+ $class_names
625
+ );
626
+
627
+ $this->debug( $message );
628
+
629
+ return false;
630
+ }
631
+
632
+ return true;
633
+ }
634
+
635
+ }
636
+ }
trunk/classes/class-wc-connect-stripe.php ADDED
@@ -0,0 +1,404 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( ! class_exists( 'WC_Connect_Stripe' ) ) {
8
+
9
+ class WC_Connect_Stripe {
10
+
11
+ /**
12
+ * @var WC_Connect_API_Client
13
+ */
14
+ private $api;
15
+
16
+ /**
17
+ * @var WC_Connect_Options
18
+ */
19
+ private $options;
20
+
21
+ /**
22
+ * @var WC_Connect_Logger
23
+ */
24
+ private $logger;
25
+
26
+ /**
27
+ * @var WC_Connect_Nux
28
+ */
29
+ private $nux;
30
+
31
+ const STATE_VAR_NAME = 'stripe_state';
32
+ const SETTINGS_OPTION = 'woocommerce_stripe_settings';
33
+ const CONNECTED_KEYS_OPTION = 'stripe_keys';
34
+
35
+ public function __construct( WC_Connect_API_Client $client, WC_Connect_Options $options, WC_Connect_Logger $logger, WC_Connect_Nux $nux ) {
36
+ $this->api = $client;
37
+ $this->options = $options;
38
+ $this->logger = $logger;
39
+ $this->nux = $nux;
40
+ }
41
+
42
+ public function is_stripe_plugin_enabled() {
43
+ return class_exists( 'WC_Stripe' );
44
+ }
45
+
46
+ public function get_oauth_url( $return_url = '' ) {
47
+ if ( empty( $return_url ) ) {
48
+ $return_url = admin_url( 'admin.php?page=wc-settings&tab=checkout&section=stripe' );
49
+ }
50
+
51
+ if ( substr( $return_url, 0, 8 ) !== 'https://' ) {
52
+ return new WP_Error( 'invalid_url_protocol', __( 'Your site must be served over HTTPS in order to connect your Stripe account via WooCommerce Services', 'woocommerce-services' ) );
53
+ }
54
+
55
+ $result = $this->api->get_stripe_oauth_init( $return_url );
56
+
57
+ if ( is_wp_error( $result ) ) {
58
+ return $result;
59
+ }
60
+
61
+ $this->options->update_option( self::STATE_VAR_NAME, $result->state );
62
+
63
+ return $result->oauthUrl;
64
+ }
65
+
66
+ public function create_account( $email, $country ) {
67
+ $response = $this->api->create_stripe_account( $email, $country );
68
+ if ( is_wp_error( $response ) ) {
69
+ return $response;
70
+ }
71
+ return $this->save_stripe_keys( $response );
72
+ }
73
+
74
+ public function get_account_details() {
75
+ if ( ! $this->is_connected() ) {
76
+ return new WP_Error(
77
+ 'not_using_wcs_for_stripe_connection',
78
+ __( 'Not using WooCommerce Services for Stripe keys. Maybe using user supplied keys.', 'woocommerce-services' ),
79
+ array(
80
+ 'status' => 400
81
+ )
82
+ );
83
+ }
84
+
85
+ $response = $this->api->get_stripe_account_details();
86
+ if ( is_wp_error( $response ) ) {
87
+ return $response;
88
+ }
89
+
90
+ return array(
91
+ 'account_id' => $response->accountId,
92
+ 'display_name' => $response->displayName,
93
+ 'email' => $response->email,
94
+ 'business_logo' => $response->businessLogo,
95
+ 'legal_entity' => array(
96
+ 'first_name' => $response->legalEntity->firstName,
97
+ 'last_name' => $response->legalEntity->lastName
98
+ ),
99
+ 'payouts_enabled' => $response->payoutsEnabled,
100
+ );
101
+ }
102
+
103
+ public function deauthorize_account() {
104
+ $response = $this->api->deauthorize_stripe_account();
105
+ if ( is_wp_error( $response ) ) {
106
+ return $response;
107
+ }
108
+
109
+ $this->clear_stripe_keys();
110
+ return $response;
111
+ }
112
+
113
+ public function connect_oauth( $state, $code ) {
114
+ if ( $state !== $this->options->get_option( self::STATE_VAR_NAME, false ) ) {
115
+ return new WP_Error( 'Invalid stripe state' );
116
+ }
117
+
118
+ $response = $this->api->get_stripe_oauth_keys( $code );
119
+
120
+ if ( is_wp_error( $response ) ) {
121
+ return $response;
122
+ }
123
+
124
+ return $this->save_stripe_keys( $response );
125
+ }
126
+
127
+ /**
128
+ * Checks if the Stripe keys currently being used are the same as the keys from the connected stripe account
129
+ *
130
+ * @return bool true if the keys match
131
+ */
132
+ public function is_connected() {
133
+ $options = get_option( self::SETTINGS_OPTION, array() );
134
+ if ( empty( $options ) ) {
135
+ return false;
136
+ }
137
+ $is_test = isset( $options['testmode'] ) && 'yes' === $options['testmode'];
138
+ $prefix = $is_test ? 'test_' : '';
139
+ $publishable_key_name = $prefix . 'publishable_key';
140
+ $secret_key_name = $prefix . 'secret_key';
141
+
142
+ $connected_keys = WC_Connect_Options::get_option( self::CONNECTED_KEYS_OPTION, array() );
143
+ if ( empty( $connected_keys ) || ! isset( $connected_keys[ $publishable_key_name ] ) || ! isset( $connected_keys[ $secret_key_name ] ) ) {
144
+ return false;
145
+ }
146
+
147
+ return wp_hash( $options[ $publishable_key_name ] ) === $connected_keys[ $publishable_key_name ]
148
+ && wp_hash( $options[ $secret_key_name ] ) === $connected_keys[ $secret_key_name ];
149
+ }
150
+
151
+ /**
152
+ * Stores the connected account's API keys in order to determine the account connection status in the future
153
+ *
154
+ * @param string $publishable_key Publishable key
155
+ * @param string $secret_key Secret key
156
+ * @param bool $is_test True if the keys are for test environment, false otherwise
157
+ */
158
+ private function set_connected_keys( $publishable_key, $secret_key, $is_test ) {
159
+ if ( empty( $publishable_key ) || empty( $secret_key ) ) {
160
+ return;
161
+ }
162
+
163
+ $prefix = $is_test ? 'test_' : '';
164
+ $publishable_key_name = $prefix . 'publishable_key';
165
+ $secret_key_name = $prefix . 'secret_key';
166
+
167
+ $connected_keys = WC_Connect_Options::get_option( self::CONNECTED_KEYS_OPTION, array() );
168
+ $connected_keys[ $publishable_key_name ] = wp_hash( $publishable_key );
169
+ $connected_keys[ $secret_key_name ] = wp_hash( $secret_key );
170
+ WC_Connect_Options::update_option( self::CONNECTED_KEYS_OPTION, $connected_keys );
171
+ }
172
+
173
+ /**
174
+ * Migrates the connection status if the site is already connected
175
+ */
176
+ private function maybe_migrate_connection_status() {
177
+ if ( $this->is_connected() ) {
178
+ return;
179
+ }
180
+ $migrated = WC_Connect_Options::get_option( 'stripe_status_migrated', false );
181
+ if ( $migrated ) {
182
+ return;
183
+ }
184
+
185
+ $account_info = $this->api->get_stripe_account_details();
186
+ if ( is_wp_error( $account_info ) ) {
187
+ //no account connected, mark the status as migrated and return
188
+ WC_Connect_Options::update_option( 'stripe_status_migrated', true );
189
+ return;
190
+ }
191
+
192
+ $options = get_option( self::SETTINGS_OPTION, array() );
193
+ if ( empty( $options ) ) {
194
+ //no stripe settings found, mark the status as migrated and return
195
+ WC_Connect_Options::update_option( 'stripe_status_migrated', true );
196
+ return;
197
+ }
198
+
199
+ //assume the currently set keys are the keys from the connected account
200
+ $this->set_connected_keys( $options['test_publishable_key'], $options['test_secret_key'], true );
201
+ $this->set_connected_keys( $options['publishable_key'], $options['secret_key'], false );
202
+ WC_Connect_Options::update_option( 'stripe_status_migrated', true );
203
+ }
204
+
205
+ private function save_stripe_keys( $result ) {
206
+ if ( ! isset( $result->publishableKey, $result->secretKey ) ) {
207
+ return new WP_Error( 'Invalid credentials received from server' );
208
+ }
209
+
210
+ $is_test = false !== strpos( $result->publishableKey, '_test_' );
211
+ $prefix = $is_test ? 'test_' : '';
212
+
213
+ $default_options = $this->get_default_stripe_config();
214
+
215
+ $options = array_merge( $default_options, get_option( self::SETTINGS_OPTION, array() ) );
216
+ $options['enabled'] = 'yes';
217
+ $options['testmode'] = $is_test ? 'yes' : 'no';
218
+ $options[ $prefix . 'publishable_key' ] = $result->publishableKey;
219
+ $options[ $prefix . 'secret_key' ] = $result->secretKey;
220
+
221
+ $this->set_connected_keys( $result->publishableKey, $result->secretKey, $is_test );
222
+
223
+ // While we are at it, let's also clear the account_id and
224
+ // test_account_id if present
225
+
226
+ // Those used to be stored by save_stripe_keys but should not have
227
+ // been since they were not used by anyone
228
+
229
+ unset( $options[ 'account_id' ] );
230
+ unset( $options[ 'test_account_id' ] );
231
+
232
+ update_option( self::SETTINGS_OPTION, $options );
233
+ return $result;
234
+ }
235
+
236
+ /**
237
+ * Clears keys for test or production (whichever is presently enabled).
238
+ * Especially useful after Stripe Connect account deauthorization.
239
+ */
240
+ private function clear_stripe_keys() {
241
+ $default_options = $this->get_default_stripe_config();
242
+ $options = array_merge( $default_options, get_option( self::SETTINGS_OPTION, array() ) );
243
+
244
+ if ( 'yes' === $options['testmode'] ) {
245
+ $options[ 'test_publishable_key' ] = '';
246
+ $options[ 'test_secret_key' ] = '';
247
+ } else {
248
+ $options[ 'publishable_key' ] = '';
249
+ $options[ 'secret_key' ] = '';
250
+ }
251
+
252
+ // While we are at it, let's also clear the account_id and
253
+ // test_account_id if present
254
+
255
+ // Those used to be stored by save_stripe_keys but should not have
256
+ // been since they were not used by anyone
257
+
258
+ unset( $options[ 'account_id' ] );
259
+ unset( $options[ 'test_account_id' ] );
260
+
261
+ update_option( self::SETTINGS_OPTION, $options );
262
+
263
+ WC_Connect_Options::delete_option( self::CONNECTED_KEYS_OPTION );
264
+ }
265
+
266
+ private function get_default_stripe_config() {
267
+ if ( ! class_exists( 'WC_Gateway_Stripe' ) ) {
268
+ return array();
269
+ }
270
+
271
+ $result = array();
272
+ $gateway = new WC_Gateway_Stripe();
273
+ foreach ( $gateway->form_fields as $key => $value ) {
274
+ if ( isset( $value['default'] ) ) {
275
+ $result[ $key ] = $value['default'];
276
+ }
277
+ }
278
+
279
+ return $result;
280
+ }
281
+
282
+ /**
283
+ * Handle connection and just-in-time messaging around OAuth flow.
284
+ */
285
+ public function maybe_show_notice() {
286
+ // Handle redirect back from OAuth flow.
287
+ if ( isset( $_GET[ 'wcs_stripe_code' ] ) && isset( $_GET[ 'wcs_stripe_state' ] ) ) {
288
+ $response = $this->connect_oauth( $_GET[ 'wcs_stripe_state' ], $_GET[ 'wcs_stripe_code' ] );
289
+ if ( ! is_wp_error( $response ) ) {
290
+ WC_Connect_Options::update_option( 'banner_stripe', 'success' );
291
+ }
292
+
293
+ wp_safe_redirect( remove_query_arg( array( 'wcs_stripe_state', 'wcs_stripe_code' ) ) );
294
+ exit;
295
+ }
296
+
297
+ // Trigger connection-related admin notice if triggered and if on relevant screen.
298
+ $setting = WC_Connect_Options::get_option( 'banner_stripe', null );
299
+ if ( is_null( $setting ) ) {
300
+ return;
301
+ }
302
+
303
+ if ( 'success' === $setting ) {
304
+ add_action( 'admin_notices', array( $this, 'connection_success_notice' ) );
305
+ WC_Connect_Options::delete_option( 'banner_stripe' );
306
+ return;
307
+ }
308
+
309
+ $screen = get_current_screen();
310
+
311
+ if ( // Display if on any of these admin pages.
312
+ 'dashboard' === $screen->id // Dashboard.
313
+ || 'plugins' === $screen->id // Plugins.
314
+ || ( // WooCommerce » Settings » Payments.
315
+ 'woocommerce_page_wc-settings' === $screen->base
316
+ && isset( $_GET['tab'] ) && 'checkout' === $_GET['tab']
317
+ )
318
+ || ( // WooCommerce » Extensions » Payments.
319
+ 'woocommerce_page_wc-addons' === $screen->base
320
+ && isset( $_GET['section'] ) && 'payment-gateways' === $_GET['section']
321
+ )
322
+ ) {
323
+ wp_enqueue_style( 'wc_connect_banner' );
324
+ add_action( 'admin_notices', array( $this, 'connection_banner' ) );
325
+ }
326
+ }
327
+
328
+ /**
329
+ * Render dismissible connection banner with OAuth link as primary action.
330
+ */
331
+ public function connection_banner() {
332
+ $result = $this->get_oauth_url();
333
+
334
+ if ( is_wp_error( $result ) ) {
335
+ //do not log the invalid url protocol error when attempting to render the banner
336
+ if ( 'invalid_url_protocol' !== $result->get_error_code() ) {
337
+ $this->logger->log( $result, __CLASS__ );
338
+ }
339
+ return;
340
+ }
341
+
342
+ $options = get_option( self::SETTINGS_OPTION, array() );
343
+ if ( ! isset( $options['email'] ) ) {
344
+ return;
345
+ }
346
+
347
+ $this->nux->show_nux_banner( array(
348
+ 'title' => __( 'Connect your account', 'woocommerce-services' ),
349
+ 'description' => wp_kses(
350
+ sprintf( __( 'It looks like there is an existing Stripe account at <strong>%s</strong>. To start accepting payments with Stripe, you\'ll need to connect it to your store.', 'woocommerce-services' ), $options['email'] ),
351
+ array( 'strong' => array() )
352
+ ),
353
+ 'button_text' => __( 'Connect', 'woocommerce-services' ),
354
+ 'button_link' => $result,
355
+ 'image_url' => plugins_url( 'images/stripe.png', dirname( __FILE__ ) ),
356
+ 'should_show_jp' => false,
357
+ 'dismissible_id' => 'stripe_connect',
358
+ 'compact_logo' => true,
359
+ ) );
360
+ }
361
+
362
+ /**
363
+ * Render admin notice acknowledging successful OAuth connection.
364
+ */
365
+ public function connection_success_notice() {
366
+ ?>
367
+ <div class="notice notice-success">
368
+ <p>
369
+ <?php echo wp_kses(
370
+ __( '<strong>Ready to accept Stripe payments!</strong> Your Stripe account has been successfully connected. Additional settings can be configured on this screen.', 'woocommerce-services' ),
371
+ array( 'strong' => array() )
372
+ ); ?>
373
+ </p>
374
+ </div>
375
+ <?php
376
+ }
377
+
378
+ /**
379
+ * Add to settings page container for dynamically rendered connected account view.
380
+ */
381
+ public function show_connected_account( $settings ) {
382
+ ob_start();
383
+ do_action( 'enqueue_wc_connect_script', 'wc-connect-stripe-connect-account' );
384
+
385
+ $this->maybe_migrate_connection_status();
386
+
387
+ // Display a different title based on the connection status.
388
+ if ( $this->is_connected() ) {
389
+ $title = __( 'Stripe Account (connected to WooCommerce Services)', 'woocommerce-services' );
390
+ } else {
391
+ $title = __( 'Connect via WooCommerce Services', 'woocommerce-services' );
392
+ }
393
+
394
+ $new_settings = array(
395
+ 'connection_status' => array(
396
+ 'type' => 'title',
397
+ 'title' => $title,
398
+ 'description' => ob_get_clean(),
399
+ ),
400
+ );
401
+ return array_merge( $new_settings, $settings );
402
+ }
403
+ }
404
+ }
trunk/classes/class-wc-connect-taxjar-integration.php ADDED
@@ -0,0 +1,1163 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class WC_Connect_TaxJar_Integration {
4
+
5
+ /**
6
+ * @var WC_Connect_API_Client
7
+ */
8
+ public $api_client;
9
+
10
+ /**
11
+ * @var WC_Connect_Logger
12
+ */
13
+ public $logger;
14
+
15
+ public $wc_connect_base_url;
16
+
17
+ private $expected_options = array(
18
+ // If automated taxes are enabled and user disables taxes we re-enable them
19
+ 'woocommerce_calc_taxes' => 'yes',
20
+ // Users can set either billing or shipping address for tax rates but not shop
21
+ 'woocommerce_tax_based_on' => 'shipping',
22
+ // Rate calculations assume tax not included
23
+ 'woocommerce_prices_include_tax' => 'no',
24
+ // Use no special handling on shipping taxes, our API handles that
25
+ 'woocommerce_shipping_tax_class' => '',
26
+ // API handles rounding precision
27
+ 'woocommerce_tax_round_at_subtotal' => 'no',
28
+ // Rates are calculated in the cart assuming tax not included
29
+ 'woocommerce_tax_display_shop' => 'excl',
30
+ // TaxJar returns one total amount, not line item amounts
31
+ 'woocommerce_tax_display_cart' => 'excl',
32
+ // TaxJar returns one total amount, not line item amounts
33
+ 'woocommerce_tax_total_display' => 'single',
34
+ );
35
+
36
+ const PROXY_PATH = 'taxjar/v2';
37
+ const OPTION_NAME = 'wc_connect_taxes_enabled';
38
+ const SETUP_WIZARD_OPTION_NAME = 'woocommerce_setup_automated_taxes';
39
+
40
+ public function __construct(
41
+ WC_Connect_API_Client $api_client,
42
+ WC_Connect_Logger $logger,
43
+ $wc_connect_base_url
44
+ ) {
45
+ $this->api_client = $api_client;
46
+ $this->logger = $logger;
47
+ $this->wc_connect_base_url = $wc_connect_base_url;
48
+
49
+ // Cache rates for 1 hour.
50
+ $this->cache_time = HOUR_IN_SECONDS;
51
+ }
52
+
53
+ public function init() {
54
+ // Only enable WCS TaxJar integration if the official TaxJar plugin isn't active.
55
+ if ( class_exists( 'WC_Taxjar' ) ) {
56
+ return;
57
+ }
58
+
59
+ $store_settings = $this->get_store_settings();
60
+ $store_country = $store_settings['country'];
61
+
62
+ // TaxJar supports USA, Canada, Australia, and the European Union
63
+ if ( ! $this->is_supported_country( $store_country ) ) {
64
+ return;
65
+ }
66
+
67
+ // Add toggle for automated taxes to the core settings page
68
+ add_filter( 'woocommerce_tax_settings', array( $this, 'add_tax_settings' ) );
69
+
70
+ // Settings values filter to handle the hardcoded settings
71
+ add_filter( 'woocommerce_admin_settings_sanitize_option', array( $this, 'sanitize_tax_option' ), 10, 2 );
72
+
73
+ // Bow out if we're not wanted
74
+ if ( ! $this->is_enabled() ) {
75
+ return;
76
+ }
77
+
78
+ // Scripts / Stylesheets
79
+ add_action( 'admin_enqueue_scripts', array( $this, 'load_taxjar_admin_new_order_assets' ) );
80
+
81
+ $this->configure_tax_settings();
82
+
83
+ // Calculate Taxes at Cart / Checkout
84
+ if ( class_exists( 'WC_Cart_Totals' ) ) { // Woo 3.2+
85
+ add_action( 'woocommerce_after_calculate_totals', array( $this, 'maybe_calculate_totals' ), 20 );
86
+ } else {
87
+ add_action( 'woocommerce_calculate_totals', array( $this, 'maybe_calculate_totals' ), 20 );
88
+ }
89
+
90
+ // Calculate Taxes for Backend Orders (Woo 2.6+)
91
+ add_action( 'woocommerce_before_save_order_items', array( $this, 'calculate_backend_totals' ), 20 );
92
+
93
+ // Set customer taxable location for local pickup
94
+ add_filter( 'woocommerce_customer_taxable_address', array( $this, 'append_base_address_to_customer_taxable_address' ), 10, 1 );
95
+
96
+ add_filter( 'woocommerce_calc_tax', array( $this, 'override_woocommerce_tax_rates' ), 10, 3 );
97
+ add_filter( 'woocommerce_matched_rates', array( $this, 'allow_street_address_for_matched_rates' ), 10, 2 );
98
+ }
99
+
100
+ /**
101
+ * Are automated taxes enabled?
102
+ *
103
+ * @return bool
104
+ */
105
+ public function is_enabled() {
106
+ // Migrate automated taxes selection from the setup wizard
107
+ if ( get_option( self::SETUP_WIZARD_OPTION_NAME ) ) {
108
+ update_option( self::OPTION_NAME, 'yes' );
109
+ delete_option( self::SETUP_WIZARD_OPTION_NAME );
110
+
111
+ return true;
112
+ }
113
+
114
+ return ( wc_tax_enabled() && 'yes' === get_option( self::OPTION_NAME ) );
115
+ }
116
+
117
+ /**
118
+ * Add our "automated taxes" setting to the core group.
119
+ *
120
+ * @param array $tax_settings WooCommerce Tax Settings
121
+ *
122
+ * @return array
123
+ */
124
+ public function add_tax_settings( $tax_settings ) {
125
+ $enabled = $this->is_enabled();
126
+
127
+ $automated_taxes = array(
128
+ 'title' => __( 'Automated taxes', 'woocommerce-services' ),
129
+ 'id' => self::OPTION_NAME, // TODO: save in `wc_connect_options`?
130
+ 'desc_tip' => __( 'Automate your sales tax calculations with WooCommerce Services, powered by Jetpack.', 'woocommerce-services' ),
131
+ 'desc' => $enabled ? '<p>' . __( 'Powered by WooCommerce Services ― Your tax rates and settings are automatically configured.', 'woocommerce-services' ) . '</p>' : '',
132
+ 'default' => 'no',
133
+ 'type' => 'select',
134
+ 'class' => 'wc-enhanced-select',
135
+ 'options' => array(
136
+ 'no' => __( 'Disable automated taxes', 'woocommerce-services' ),
137
+ 'yes' => __( 'Enable automated taxes', 'woocommerce-services' ),
138
+ ),
139
+ );
140
+
141
+ // Insert the "automated taxes" setting at the top (under the section title)
142
+ array_splice( $tax_settings, 1, 0, array( $automated_taxes ) );
143
+
144
+ if ( $enabled ) {
145
+ // If the automated taxes are enabled, disable the settings that would be reverted in the original plugin
146
+ foreach ( $tax_settings as $index => $tax_setting ) {
147
+ if ( ! array_key_exists( $tax_setting['id'], $this->expected_options ) ) {
148
+ continue;
149
+ }
150
+ $tax_settings[$index]['custom_attributes'] = array( 'disabled' => true );
151
+ }
152
+ }
153
+
154
+ return $tax_settings;
155
+ }
156
+
157
+ /**
158
+ * When automated taxes are enabled, overwrite core tax settings that might break the API integration
159
+ * This is similar to the original plugin functionality where these options were reverted on page load
160
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/82bf7c58/includes/class-wc-taxjar-integration.php#L66-L91
161
+ *
162
+ * @param mixed $value - option value
163
+ * @param array $option - option metadata
164
+ * @return string new option value, based on the automated taxes state or $value
165
+ */
166
+ public function sanitize_tax_option( $value, $option ) {
167
+ if (
168
+ //skip unrecognized option format
169
+ ! is_array( $option )
170
+ //skip if unexpected option format
171
+ || ! isset( $option['id'] )
172
+ //skip if not enabled or not being enabled in the current request
173
+ || ! $this->is_enabled() && ( ! isset( $_POST[self::OPTION_NAME] ) || 'yes' != $_POST[self::OPTION_NAME] ) ) {
174
+ return $value;
175
+ }
176
+
177
+ //the option is currently being enabled - backup the rates and flush the rates table
178
+ if ( ! $this->is_enabled() && self::OPTION_NAME === $option['id'] && 'yes' === $value ) {
179
+ $this->backup_existing_tax_rates();
180
+ return $value;
181
+ }
182
+
183
+ //skip if unexpected option
184
+ if ( ! array_key_exists( $option['id'], $this->expected_options ) ) {
185
+ return $value;
186
+ }
187
+
188
+ return $this->expected_options[ $option['id'] ];
189
+ }
190
+
191
+ /**
192
+ * Overwrite WooCommerce core tax settings if they are different than expected
193
+ *
194
+ * Ported from TaxJar's plugin and modified to support $this->expected_options
195
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/82bf7c58/includes/class-wc-taxjar-integration.php#L66-L91
196
+ */
197
+ public function configure_tax_settings() {
198
+ foreach( $this->expected_options as $option => $value ) {
199
+ //first check the option value - with default memory caching this should help to avoid unnecessary DB operations
200
+ if ( get_option( $option ) !== $value ) {
201
+ update_option( $option, $value );
202
+ }
203
+ }
204
+ }
205
+
206
+ /**
207
+ * TaxJar supports USA, Canada, Australia, and the European Union
208
+ * See: https://developers.taxjar.com/api/reference/#countries
209
+ *
210
+ * @return array Countries supported by TaxJar.
211
+ */
212
+ public function get_supported_countries() {
213
+ $supported_countries = array_merge(
214
+ array(
215
+ 'US',
216
+ 'CA',
217
+ 'AU',
218
+ ),
219
+ WC()->countries->get_european_union_countries()
220
+ );
221
+
222
+ return $supported_countries;
223
+ }
224
+
225
+ /**
226
+ * Check if a given country is supported by TaxJar.
227
+ *
228
+ * @param $country Two character country code.
229
+ *
230
+ * @return bool Whether or not the country is supported by TaxJar.
231
+ */
232
+ public function is_supported_country( $country ) {
233
+ return in_array( $country, $this->get_supported_countries() );
234
+ }
235
+
236
+ /**
237
+ * Gets the store's location settings.
238
+ *
239
+ * Modified version of TaxJar's plugin.
240
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/4b481f5/includes/class-wc-taxjar-integration.php#L910
241
+ *
242
+ * @return array
243
+ */
244
+ public function get_store_settings() {
245
+ $store_settings = array(
246
+ 'street' => WC()->countries->get_base_address(),
247
+ 'city' => WC()->countries->get_base_city(),
248
+ 'state' => WC()->countries->get_base_state(),
249
+ 'country' => WC()->countries->get_base_country(),
250
+ 'postcode' => WC()->countries->get_base_postcode(),
251
+ );
252
+
253
+ return apply_filters( 'taxjar_store_settings', $store_settings, array() );
254
+ }
255
+
256
+ /**
257
+ * @param $message
258
+ */
259
+ public function _log( $message ) {
260
+ $formatted_message = is_scalar( $message ) ? $message : json_encode( $message );
261
+
262
+ $this->logger->log( $formatted_message, 'WCS Tax' );
263
+ }
264
+
265
+ /**
266
+ * @param $message
267
+ */
268
+ public function _error( $message ) {
269
+ $formatted_message = is_scalar( $message ) ? $message : json_encode( $message );
270
+
271
+ //ignore error messages caused by customer input
272
+ $state_zip_mismatch = false !== strpos( $formatted_message, 'to_zip' ) && false !== strpos( $formatted_message, 'is not used within to_state' );
273
+ $invalid_postcode = false !== strpos( $formatted_message, 'isn\'t a valid postal code for' );
274
+ if ( ! is_admin() && ( $state_zip_mismatch || $invalid_postcode ) ) {
275
+ $fields = WC()->countries->get_address_fields();
276
+ $postcode_field_name = __( 'Postcode / ZIP', 'woocommerce-services' );
277
+ if ( isset( $fields['billing_postcode'] ) && isset( $fields['billing_postcode']['label'] ) ) {
278
+ $postcode_field_name = $fields['billing_postcode']['label'];
279
+ }
280
+
281
+ if ( $state_zip_mismatch ) {
282
+ $message = sprintf( _x( '%s does not match the selected state.', '%s - Postcode/Zip checkout field label', 'woocommerce-services' ), $postcode_field_name );
283
+ } else {
284
+ $message = sprintf( _x( 'Invalid %s entered.', '%s - Postcode/Zip checkout field label', 'woocommerce-services' ), $postcode_field_name );
285
+ }
286
+
287
+ if ( ! wc_has_notice( $message, 'error' ) ) {
288
+ wc_add_notice( $message, 'error' );
289
+ }
290
+
291
+ return;
292
+ }
293
+
294
+ $this->logger->error( $formatted_message, 'WCS Tax' );
295
+ }
296
+
297
+ /**
298
+ * Wrapper to avoid calling calculate_totals() for admin carts.
299
+ *
300
+ * @param $wc_cart_object
301
+ */
302
+ public function maybe_calculate_totals( $wc_cart_object ) {
303
+ if ( ! WC_Connect_Functions::should_send_cart_api_request() ) {
304
+ return;
305
+ }
306
+
307
+ $this->calculate_totals( $wc_cart_object );
308
+ }
309
+ /**
310
+ * Calculate tax / totals using TaxJar at checkout
311
+ *
312
+ * Unchanged from the TaxJar plugin.
313
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/4b481f5/includes/class-wc-taxjar-integration.php#L471
314
+ *
315
+ * @return void
316
+ */
317
+ public function calculate_totals( $wc_cart_object ) {
318
+ // If outside of cart and checkout page or within mini-cart, skip calculations
319
+ if ( ( ! is_cart() && ! is_checkout() ) || ( is_cart() && is_ajax() ) ) {
320
+ return;
321
+ }
322
+
323
+ $cart_taxes = array();
324
+ $cart_tax_total = 0;
325
+
326
+ foreach ( $wc_cart_object->coupons as $coupon ) {
327
+ if ( method_exists( $coupon, 'get_id' ) ) { // Woo 3.0+
328
+ $limit_usage_qty = get_post_meta( $coupon->get_id(), 'limit_usage_to_x_items', true );
329
+
330
+ if ( $limit_usage_qty ) {
331
+ $coupon->set_limit_usage_to_x_items( $limit_usage_qty );
332
+ }
333
+ }
334
+ }
335
+
336
+ $address = $this->get_address( $wc_cart_object );
337
+ $line_items = $this->get_line_items( $wc_cart_object );
338
+
339
+ $taxes = $this->calculate_tax( array(
340
+ 'to_country' => $address['to_country'],
341
+ 'to_zip' => $address['to_zip'],
342
+ 'to_state' => $address['to_state'],
343
+ 'to_city' => $address['to_city'],
344
+ 'to_street' => $address['to_street'],
345
+ 'shipping_amount' => WC()->shipping->shipping_total,
346
+ 'line_items' => $line_items,
347
+ ) );
348
+
349
+ $this->response_rate_ids = $taxes['rate_ids'];
350
+ $this->response_line_items = $taxes['line_items'];
351
+
352
+ if ( isset( $this->response_line_items ) ) {
353
+ foreach ( $this->response_line_items as $response_line_item_key => $response_line_item ) {
354
+ $line_item = $this->get_line_item( $response_line_item_key, $line_items );
355
+ if ( isset( $line_item ) ) {
356
+ $this->response_line_items[ $response_line_item_key ]->line_total = ( $line_item['unit_price'] * $line_item['quantity'] ) - $line_item['discount'];
357
+ }
358
+ }
359
+ }
360
+
361
+ foreach ( $wc_cart_object->get_cart() as $cart_item_key => $cart_item ) {
362
+ $product = $cart_item['data'];
363
+ $line_item_key = $product->get_id() . '-' . $cart_item_key;
364
+ if ( isset( $taxes['line_items'][ $line_item_key ] ) && ! $taxes['line_items'][ $line_item_key ]->combined_tax_rate ) {
365
+ if ( method_exists( $product, 'set_tax_status' ) ) {
366
+ $product->set_tax_status( 'none' ); // Woo 3.0+
367
+ } else {
368
+ $product->tax_status = 'none'; // Woo 2.6
369
+ }
370
+ }
371
+ }
372
+
373
+ // Recalculate shipping package rates
374
+ foreach ( $wc_cart_object->get_shipping_packages() as $package_key => $package ) {
375
+ WC()->session->set( 'shipping_for_package_' . $package_key, null );
376
+ }
377
+
378
+ if ( class_exists( 'WC_Cart_Totals' ) ) { // Woo 3.2+
379
+ do_action( 'woocommerce_cart_reset', $wc_cart_object, false );
380
+ do_action( 'woocommerce_before_calculate_totals', $wc_cart_object );
381
+ new WC_Cart_Totals( $wc_cart_object );
382
+ remove_action( 'woocommerce_after_calculate_totals', array( $this, 'maybe_calculate_totals' ), 20 );
383
+ do_action( 'woocommerce_after_calculate_totals', $wc_cart_object );
384
+ add_action( 'woocommerce_after_calculate_totals', array( $this, 'maybe_calculate_totals' ), 20 );
385
+ } else {
386
+ remove_action( 'woocommerce_calculate_totals', array( $this, 'maybe_calculate_totals' ), 20 );
387
+ $wc_cart_object->calculate_totals();
388
+ add_action( 'woocommerce_calculate_totals', array( $this, 'maybe_calculate_totals' ), 20 );
389
+ }
390
+ }
391
+
392
+ /**
393
+ * Calculate tax / totals using TaxJar for backend orders
394
+ *
395
+ * Unchanged from the TaxJar plugin.
396
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/96b5d57/includes/class-wc-taxjar-integration.php#L557
397
+ *
398
+ * @return void
399
+ */
400
+ public function calculate_backend_totals( $order_id ) {
401
+ $order = wc_get_order( $order_id );
402
+ $address = $this->get_backend_address();
403
+ $line_items = $this->get_backend_line_items( $order );
404
+ if ( method_exists( $order, 'get_shipping_total' ) ) {
405
+ $shipping = $order->get_shipping_total(); // Woo 3.0+
406
+ } else {
407
+ $shipping = $order->get_total_shipping(); // Woo 2.6
408
+ }
409
+ $taxes = $this->calculate_tax( array(
410
+ 'to_country' => $address['to_country'],
411
+ 'to_state' => $address['to_state'],
412
+ 'to_zip' => $address['to_zip'],
413
+ 'to_city' => $address['to_city'],
414
+ 'to_street' => $address['to_street'],
415
+ 'shipping_amount' => $shipping,
416
+ 'line_items' => $line_items,
417
+ ) );
418
+ if ( class_exists( 'WC_Order_Item_Tax' ) ) { // Add tax rates manually for Woo 3.0+
419
+ foreach ( $order->get_items() as $item_key => $item ) {
420
+ $product_id = $item->get_product_id();
421
+ $line_item_key = $product_id . '-' . $item_key;
422
+ if ( isset( $taxes['rate_ids'][ $line_item_key ] ) ) {
423
+ $rate_id = $taxes['rate_ids'][ $line_item_key ];
424
+ $item_tax = new WC_Order_Item_Tax();
425
+ $item_tax->set_rate( $rate_id );
426
+ $item_tax->set_order_id( $order_id );
427
+ $item_tax->save();
428
+ }
429
+ }
430
+ } else { // Recalculate tax for Woo 2.6 to apply new tax rates
431
+ if ( class_exists( 'WC_AJAX' ) ) {
432
+ remove_action( 'woocommerce_before_save_order_items', array( $this, 'calculate_backend_totals' ), 20 );
433
+ if ( check_ajax_referer( 'calc-totals', 'security', false ) ) {
434
+ WC_AJAX::calc_line_taxes();
435
+ }
436
+ add_action( 'woocommerce_before_save_order_items', array( $this, 'calculate_backend_totals' ), 20 );
437
+ }
438
+ }
439
+ }
440
+
441
+ /**
442
+ * Get address details of customer at checkout
443
+ *
444
+ * Unchanged from the TaxJar plugin.
445
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/4b481f5/includes/class-wc-taxjar-integration.php#L585
446
+ *
447
+ * @return array
448
+ */
449
+ protected function get_address() {
450
+ $taxable_address = $this->get_taxable_address();
451
+ $taxable_address = is_array( $taxable_address ) ? $taxable_address : array();
452
+
453
+ $to_country = isset( $taxable_address[0] ) && ! empty( $taxable_address[0] ) ? $taxable_address[0] : false;
454
+ $to_state = isset( $taxable_address[1] ) && ! empty( $taxable_address[1] ) ? $taxable_address[1] : false;
455
+ $to_zip = isset( $taxable_address[2] ) && ! empty( $taxable_address[2] ) ? $taxable_address[2] : false;
456
+ $to_city = isset( $taxable_address[3] ) && ! empty( $taxable_address[3] ) ? $taxable_address[3] : false;
457
+ $to_street = isset( $taxable_address[4] ) && ! empty( $taxable_address[4] ) ? $taxable_address[4] : false;
458
+
459
+ return array(
460
+ 'to_country' => $to_country,
461
+ 'to_state' => $to_state,
462
+ 'to_zip' => $to_zip,
463
+ 'to_city' => $to_city,
464
+ 'to_street' => $to_street,
465
+ );
466
+ }
467
+
468
+ /**
469
+ * Allow street address to be passed when finding rates
470
+ *
471
+ * @param array $matched_tax_rates
472
+ * @param string $tax_class
473
+ * @return array
474
+ */
475
+ public function allow_street_address_for_matched_rates( $matched_tax_rates, $tax_class = '' ) {
476
+ $tax_class = sanitize_title( $tax_class );
477
+ $location = WC_Tax::get_tax_location( $tax_class );
478
+ $matched_tax_rates = array();
479
+ if ( sizeof( $location ) >= 4 ) {
480
+ list( $country, $state, $postcode, $city, $street ) = array_pad( $location, 5, '' );
481
+ $matched_tax_rates = WC_Tax::find_rates( array(
482
+ 'country' => $country,
483
+ 'state' => $state,
484
+ 'postcode' => $postcode,
485
+ 'city' => $city,
486
+ 'tax_class' => $tax_class,
487
+ ) );
488
+ }
489
+ return $matched_tax_rates;
490
+ }
491
+
492
+ /**
493
+ * Get taxable address.
494
+ * @return array
495
+ */
496
+ public function get_taxable_address() {
497
+ $tax_based_on = get_option( 'woocommerce_tax_based_on' );
498
+ // Check shipping method at this point to see if we need special handling
499
+ // See WC_Customer get_taxable_address()
500
+ // wc_get_chosen_shipping_method_ids() available since Woo 2.6.2+
501
+ if ( function_exists( 'wc_get_chosen_shipping_method_ids' ) ) {
502
+ if ( true === apply_filters( 'woocommerce_apply_base_tax_for_local_pickup', true ) && sizeof( array_intersect( wc_get_chosen_shipping_method_ids(), apply_filters( 'woocommerce_local_pickup_methods', array( 'legacy_local_pickup', 'local_pickup' ) ) ) ) > 0 ) {
503
+ $tax_based_on = 'base';
504
+ }
505
+ } else {
506
+ if ( true === apply_filters( 'woocommerce_apply_base_tax_for_local_pickup', true ) && sizeof( array_intersect( WC()->session->get( 'chosen_shipping_methods', array() ), apply_filters( 'woocommerce_local_pickup_methods', array( 'legacy_local_pickup', 'local_pickup' ) ) ) ) > 0 ) {
507
+ $tax_based_on = 'base';
508
+ }
509
+ }
510
+
511
+ if ( 'base' === $tax_based_on ) {
512
+ $store_settings = $this->get_store_settings();
513
+ $country = $store_settings['country'];
514
+ $state = $store_settings['state'];
515
+ $postcode = $store_settings['postcode'];
516
+ $city = $store_settings['city'];
517
+ $street = $store_settings['street'];
518
+ } elseif ( 'billing' === $tax_based_on ) {
519
+ $country = WC()->customer->get_billing_country();
520
+ $state = WC()->customer->get_billing_state();
521
+ $postcode = WC()->customer->get_billing_postcode();
522
+ $city = WC()->customer->get_billing_city();
523
+ $street = WC()->customer->get_billing_address();
524
+ } else {
525
+ $country = WC()->customer->get_shipping_country();
526
+ $state = WC()->customer->get_shipping_state();
527
+ $postcode = WC()->customer->get_shipping_postcode();
528
+ $city = WC()->customer->get_shipping_city();
529
+ $street = WC()->customer->get_shipping_address();
530
+ }
531
+
532
+ return apply_filters( 'woocommerce_customer_taxable_address', array( $country, $state, $postcode, $city, $street ) );
533
+ }
534
+
535
+ /**
536
+ * Get address details of customer for backend orders
537
+ *
538
+ * Unchanged from the TaxJar plugin.
539
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/4b481f5/includes/class-wc-taxjar-integration.php#L607
540
+ *
541
+ * @return array
542
+ */
543
+ protected function get_backend_address() {
544
+ $to_country = isset( $_POST['country'] ) ? strtoupper( wc_clean( $_POST['country'] ) ) : false;
545
+ $to_state = isset( $_POST['state'] ) ? strtoupper( wc_clean( $_POST['state'] ) ) : false;
546
+ $to_zip = isset( $_POST['postcode'] ) ? strtoupper( wc_clean( $_POST['postcode'] ) ) : false;
547
+ $to_city = isset( $_POST['city'] ) ? strtoupper( wc_clean( $_POST['city'] ) ) : false;
548
+ $to_street = isset( $_POST['street'] ) ? strtoupper( wc_clean( $_POST['street'] ) ) : false;
549
+
550
+ return array(
551
+ 'to_country' => $to_country,
552
+ 'to_state' => $to_state,
553
+ 'to_zip' => $to_zip,
554
+ 'to_city' => $to_city,
555
+ 'to_street' => $to_street,
556
+ );
557
+ }
558
+
559
+ /**
560
+ * Get line items at checkout
561
+ *
562
+ * Unchanged from the TaxJar plugin.
563
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/96b5d57/includes/class-wc-taxjar-integration.php#L645
564
+ *
565
+ * @return array
566
+ */
567
+ protected function get_line_items( $wc_cart_object ) {
568
+ $line_items = array();
569
+
570
+ foreach ( $wc_cart_object->get_cart() as $cart_item_key => $cart_item ) {
571
+ $product = $cart_item['data'];
572
+ $id = $product->get_id();
573
+ $quantity = $cart_item['quantity'];
574
+ $unit_price = wc_format_decimal( $product->get_price() );
575
+ $line_subtotal = wc_format_decimal( $cart_item['line_subtotal'] );
576
+ $discount = wc_format_decimal( $cart_item['line_subtotal'] - $cart_item['line_total'] );
577
+ $tax_class = explode( '-', $product->get_tax_class() );
578
+ $tax_code = '';
579
+
580
+ if ( isset( $tax_class ) && is_numeric( end( $tax_class ) ) ) {
581
+ $tax_code = end( $tax_class );
582
+ }
583
+
584
+ if ( ! $product->is_taxable() || 'zero-rate' == sanitize_title( $product->get_tax_class() ) ) {
585
+ $tax_code = '99999';
586
+ }
587
+
588
+ // Get WC Subscription sign-up fees for calculations
589
+ if ( class_exists( 'WC_Subscriptions_Cart' ) ) {
590
+ if ( 'none' == WC_Subscriptions_Cart::get_calculation_type() ) {
591
+ if ( class_exists( 'WC_Subscriptions_Synchroniser' ) ) {
592
+ WC_Subscriptions_Synchroniser::maybe_set_free_trial();
593
+ }
594
+ $unit_price = WC_Subscriptions_Cart::set_subscription_prices_for_calculation( $unit_price, $product );
595
+ }
596
+ }
597
+
598
+ if ( $unit_price && $line_subtotal ) {
599
+ array_push($line_items, array(
600
+ 'id' => $id . '-' . $cart_item_key,
601
+ 'quantity' => $quantity,
602
+ 'product_tax_code' => $tax_code,
603
+ 'unit_price' => $unit_price,
604
+ 'discount' => $discount,
605
+ ));
606
+ }
607
+ }
608
+
609
+ return $line_items;
610
+ }
611
+
612
+ /**
613
+ * Get line items for backend orders
614
+ *
615
+ * Unchanged from the TaxJar plugin.
616
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/96b5d57/includes/class-wc-taxjar-integration.php#L695
617
+ *
618
+ * @return array
619
+ */
620
+ protected function get_backend_line_items( $order ) {
621
+ $line_items = array();
622
+ $this->backend_tax_classes = array();
623
+ foreach ( $order->get_items() as $item_key => $item ) {
624
+ if ( is_object( $item ) ) { // Woo 3.0+
625
+ $id = $item->get_product_id();
626
+ $quantity = $item->get_quantity();
627
+ $unit_price = wc_format_decimal( $item->get_subtotal() / $quantity );
628
+ $discount = wc_format_decimal( $item->get_subtotal() - $item->get_total() );
629
+ $tax_class_name = $item->get_tax_class();
630
+ $tax_status = $item->get_tax_status();
631
+ } else { // Woo 2.6
632
+ $id = $item['product_id'];
633
+ $quantity = $item['qty'];
634
+ $unit_price = wc_format_decimal( $item['line_subtotal'] / $quantity );
635
+ $discount = wc_format_decimal( $item['line_subtotal'] - $item['line_total'] );
636
+ $tax_class_name = $item['tax_class'];
637
+ $product = $order->get_product_from_item( $item );
638
+ $tax_status = $product ? $product->get_tax_status() : 'taxable';
639
+ }
640
+ $this->backend_tax_classes[$id] = $tax_class_name;
641
+ $tax_class = explode( '-', $tax_class_name );
642
+ $tax_code = '';
643
+ if ( isset( $tax_class[1] ) && is_numeric( $tax_class[1] ) ) {
644
+ $tax_code = $tax_class[1];
645
+ }
646
+ if ( 'taxable' !== $tax_status ) {
647
+ $tax_code = '99999';
648
+ }
649
+ if ( $unit_price ) {
650
+ array_push($line_items, array(
651
+ 'id' => $id . '-' . $item_key,
652
+ 'quantity' => $quantity,
653
+ 'product_tax_code' => $tax_code,
654
+ 'unit_price' => $unit_price,
655
+ 'discount' => $discount,
656
+ ));
657
+ }
658
+ }
659
+ return $line_items;
660
+ }
661
+
662
+ protected function get_line_item( $id, $line_items ) {
663
+ foreach ( $line_items as $line_item ) {
664
+ if ( $line_item['id'] === $id ) {
665
+ return $line_item;
666
+ }
667
+ }
668
+ return null;
669
+ }
670
+
671
+ /**
672
+ * Override Woo's native tax rates to handle multiple line items with the same tax rate
673
+ * within the same tax class with different rates due to exemption thresholds
674
+ *
675
+ * Unchanged from the TaxJar plugin.
676
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/4b481f5/includes/class-wc-taxjar-integration.php#L729
677
+ *
678
+ * @return array
679
+ */
680
+ public function override_woocommerce_tax_rates( $taxes, $price, $rates ) {
681
+ if ( isset( $this->response_line_items ) && array_values( $rates ) ) {
682
+ // Get tax rate ID for current item
683
+ $keys = array_keys( $taxes );
684
+ $tax_rate_id = $keys[0];
685
+ $line_items = array();
686
+
687
+ // Map line items using rate ID
688
+ foreach ( $this->response_rate_ids as $line_item_key => $rate_id ) {
689
+ if ( $rate_id == $tax_rate_id ) {
690
+ $line_items[] = $line_item_key;
691
+ }
692
+ }
693
+
694
+ // Remove number precision if Woo 3.2+
695
+ if ( function_exists( 'wc_remove_number_precision' ) ) {
696
+ $price = wc_remove_number_precision( $price );
697
+ }
698
+
699
+ foreach ( $this->response_line_items as $line_item_key => $line_item ) {
700
+ // If line item belongs to rate and matches the price, manually set the tax
701
+ if ( in_array( $line_item_key, $line_items ) && $price == $line_item->line_total ) {
702
+ if ( function_exists( 'wc_add_number_precision' ) ) {
703
+ $taxes[ $tax_rate_id ] = wc_add_number_precision( $line_item->tax_collectable );
704
+ } else {
705
+ $taxes[ $tax_rate_id ] = $line_item->tax_collectable;
706
+ }
707
+ }
708
+ }
709
+ }
710
+
711
+ return $taxes;
712
+ }
713
+
714
+ /**
715
+ * Set customer zip code and state to store if local shipping option set
716
+ *
717
+ * Unchanged from the TaxJar plugin.
718
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/82bf7c587/includes/class-wc-taxjar-integration.php#L653
719
+ *
720
+ * @return array
721
+ */
722
+ public function append_base_address_to_customer_taxable_address( $address ) {
723
+ $tax_based_on = '';
724
+
725
+ list( $country, $state, $postcode, $city, $street ) = array_pad( $address, 5, '' );
726
+
727
+ // See WC_Customer get_taxable_address()
728
+ // wc_get_chosen_shipping_method_ids() available since Woo 2.6.2+
729
+ if ( function_exists( 'wc_get_chosen_shipping_method_ids' ) ) {
730
+ if ( true === apply_filters( 'woocommerce_apply_base_tax_for_local_pickup', true ) && sizeof( array_intersect( wc_get_chosen_shipping_method_ids(), apply_filters( 'woocommerce_local_pickup_methods', array( 'legacy_local_pickup', 'local_pickup' ) ) ) ) > 0 ) {
731
+ $tax_based_on = 'base';
732
+ }
733
+ } else {
734
+ if ( true === apply_filters( 'woocommerce_apply_base_tax_for_local_pickup', true ) && sizeof( array_intersect( WC()->session->get( 'chosen_shipping_methods', array() ), apply_filters( 'woocommerce_local_pickup_methods', array( 'legacy_local_pickup', 'local_pickup' ) ) ) ) > 0 ) {
735
+ $tax_based_on = 'base';
736
+ }
737
+ }
738
+
739
+ if ( 'base' == $tax_based_on ) {
740
+ $store_settings = $this->get_store_settings();
741
+ $postcode = $store_settings['postcode'];
742
+ $city = strtoupper( $store_settings['city'] );
743
+ $street = $store_settings['street'];
744
+ }
745
+
746
+ if ( '' != $street ) {
747
+ return array( $country, $state, $postcode, $city, $street );
748
+ } else {
749
+ return array( $country, $state, $postcode, $city );
750
+ }
751
+
752
+ return array( $country, $state, $postcode, $city );
753
+ }
754
+
755
+ /**
756
+ * Calculate sales tax using SmartCalcs
757
+ *
758
+ * Direct from the TaxJar plugin, without Nexus check.
759
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/96b5d57/includes/class-wc-taxjar-integration.php#L247
760
+ *
761
+ *
762
+ * @return void
763
+ */
764
+ public function calculate_tax( $options = array() ) {
765
+ $this->_log( ':::: TaxJar Plugin requested ::::' );
766
+
767
+ // Process $options array and turn them into variables
768
+ $options = is_array( $options ) ? $options : array();
769
+
770
+ extract( array_replace_recursive(array(
771
+ 'to_country' => null,
772
+ 'to_state' => null,
773
+ 'to_zip' => null,
774
+ 'to_city' => null,
775
+ 'to_street' => null,
776
+ 'shipping_amount' => null, // WC()->shipping->shipping_total
777
+ 'line_items' => null,
778
+ ), $options) );
779
+
780
+ $taxes = array(
781
+ 'freight_taxable' => 1,
782
+ 'has_nexus' => 0,
783
+ 'line_items' => array(),
784
+ 'rate_ids' => array(),
785
+ 'tax_rate' => 0,
786
+ );
787
+
788
+ // Strict conditions to be met before API call can be conducted
789
+ if (
790
+ empty( $to_country ) ||
791
+ empty( $to_zip ) ||
792
+ ( empty( $line_items ) && ( 0 == $shipping_amount ) ) ||
793
+ WC()->customer->is_vat_exempt()
794
+ ) {
795
+ return false;
796
+ }
797
+
798
+ $to_zip = explode( ',' , $to_zip );
799
+ $to_zip = array_shift( $to_zip );
800
+
801
+ $store_settings = $this->get_store_settings();
802
+ $from_country = $store_settings['country'];
803
+ $from_state = $store_settings['state'];
804
+ $from_zip = $store_settings['postcode'];
805
+ $from_city = $store_settings['city'];
806
+ $from_street = $store_settings['street'];
807
+ $shipping_amount = is_null( $shipping_amount ) ? 0.0 : $shipping_amount;
808
+
809
+ $this->_log( ':::: TaxJar API called ::::' );
810
+
811
+ $body = array(
812
+ 'from_country' => $from_country,
813
+ 'from_state' => $from_state,
814
+ 'from_zip' => $from_zip,
815
+ 'from_city' => $from_city,
816
+ 'from_street' => $from_street,
817
+ 'to_country' => $to_country,
818
+ 'to_state' => $to_state,
819
+ 'to_zip' => $to_zip,
820
+ 'to_city' => $to_city,
821
+ 'to_street' => $to_street,
822
+ 'shipping' => $shipping_amount,
823
+ 'plugin' => 'woo',
824
+ );
825
+
826
+ // Either `amount` or `line_items` parameters are required to perform tax calculations.
827
+ if ( empty( $line_items ) ) {
828
+ $body['amount'] = 0.0;
829
+ } else {
830
+ $body['line_items'] = $line_items;
831
+ }
832
+
833
+ $response = $this->smartcalcs_cache_request( wp_json_encode( $body ) );
834
+
835
+ if ( isset( $response ) ) {
836
+ // Log the response
837
+ $this->_log( 'Received: ' . $response['body'] );
838
+
839
+ // Decode Response
840
+ $taxjar_response = json_decode( $response['body'] );
841
+ $taxjar_response = $taxjar_response->tax;
842
+
843
+ // Update Properties based on Response
844
+ $taxes['freight_taxable'] = (int) $taxjar_response->freight_taxable;
845
+ $taxes['has_nexus'] = (int) $taxjar_response->has_nexus;
846
+ $taxes['tax_rate'] = $taxjar_response->rate;
847
+
848
+ if ( ! empty( $taxjar_response->breakdown ) ) {
849
+ if ( ! empty( $taxjar_response->breakdown->line_items ) ) {
850
+ $line_items = array();
851
+ foreach ( $taxjar_response->breakdown->line_items as $line_item ) {
852
+ $line_items[ $line_item->id ] = $line_item;
853
+ }
854
+ $taxes['line_items'] = $line_items;
855
+ }
856
+ }
857
+ }
858
+
859
+ // Remove taxes if they are set somehow and customer is exempt
860
+ if ( WC()->customer->is_vat_exempt() ) {
861
+ $wc_cart_object->remove_taxes();
862
+ } elseif ( $taxes['has_nexus'] ) {
863
+ // Use Woo core to find matching rates for taxable address
864
+ $location = array(
865
+ 'to_country' => $to_country,
866
+ 'to_state' => $to_state,
867
+ 'to_zip' => $to_zip,
868
+ 'to_city' => $to_city,
869
+ );
870
+
871
+ // Add line item tax rates
872
+ foreach ( $taxes['line_items'] as $line_item_key => $line_item ) {
873
+ $line_item_key_chunks = explode( '-', $line_item_key );
874
+ $product_id = $line_item_key_chunks[0];
875
+ $product = wc_get_product( $product_id );
876
+
877
+ if ( $product ) {
878
+ $tax_class = $product->get_tax_class();
879
+ } else {
880
+ if ( isset( $this->backend_tax_classes[$product_id] ) ) {
881
+ $tax_class = $this->backend_tax_classes[$product_id];
882
+ }
883
+ }
884
+
885
+ if ( $line_item->combined_tax_rate ) {
886
+ $taxes['rate_ids'][ $line_item_key ] = $this->create_or_update_tax_rate(
887
+ $location,
888
+ $line_item->combined_tax_rate * 100,
889
+ $tax_class,
890
+ $taxes['freight_taxable']
891
+ );
892
+ }
893
+ }
894
+
895
+ // Add shipping tax rate
896
+ if ( $taxes['tax_rate'] ) {
897
+ $taxes['rate_ids']['shipping'] = $this->create_or_update_tax_rate(
898
+ $location,
899
+ $taxes['tax_rate'] * 100,
900
+ '',
901
+ $taxes['freight_taxable']
902
+ );
903
+ }
904
+ } // End if().
905
+
906
+ return $taxes;
907
+ } // End calculate_tax().
908
+
909
+ /**
910
+ * Add or update a native WooCommerce tax rate
911
+ *
912
+ * Unchanged from the TaxJar plugin.
913
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/9d8e725/includes/class-wc-taxjar-integration.php#L396
914
+ *
915
+ * @return void
916
+ */
917
+ public function create_or_update_tax_rate( $location, $rate, $tax_class = '', $freight_taxable = 1 ) {
918
+ $tax_rate = array(
919
+ 'tax_rate_country' => $location['to_country'],
920
+ 'tax_rate_state' => $location['to_state'],
921
+ 'tax_rate_name' => sprintf( "%s Tax", $location['to_state'] ),
922
+ 'tax_rate_priority' => 1,
923
+ 'tax_rate_compound' => false,
924
+ 'tax_rate_shipping' => $freight_taxable,
925
+ 'tax_rate' => $rate,
926
+ 'tax_rate_class' => $tax_class,
927
+ );
928
+
929
+ $wc_rate = WC_Tax::find_rates( array(
930
+ 'country' => $location['to_country'],
931
+ 'state' => $location['to_state'],
932
+ 'postcode' => $location['to_zip'],
933
+ 'city' => $location['to_city'],
934
+ 'tax_class' => $tax_class,
935
+ ) );
936
+
937
+ if ( ! empty( $wc_rate ) ) {
938
+ $this->_log( ':: Tax Rate Found ::' );
939
+ $this->_log( $wc_rate );
940
+
941
+ // Get the existing ID
942
+ $rate_id = key( $wc_rate );
943
+
944
+ // Update Tax Rates with TaxJar rates ( rates might be coming from a cached taxjar rate )
945
+ $this->_log( ':: Updating Tax Rate To ::' );
946
+ $this->_log( $tax_rate );
947
+
948
+ WC_Tax::_update_tax_rate( $rate_id, $tax_rate );
949
+ } else {
950
+ // Insert a rate if we did not find one
951
+ $this->_log( ':: Adding New Tax Rate ::' );
952
+ $this->_log( $tax_rate );
953
+ $rate_id = WC_Tax::_insert_tax_rate( $tax_rate );
954
+ WC_Tax::_update_tax_rate_postcodes( $rate_id, wc_clean( $location['to_zip'] ) );
955
+ WC_Tax::_update_tax_rate_cities( $rate_id, wc_clean( $location['to_city'] ) );
956
+ }
957
+
958
+ $this->_log( 'Tax Rate ID Set for ' . $rate_id );
959
+ return $rate_id;
960
+ }
961
+
962
+ /**
963
+ * Wrap SmartCalcs API requests in a transient-based caching layer.
964
+ *
965
+ * Unchanged from the TaxJar plugin.
966
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/4b481f5/includes/class-wc-taxjar-integration.php#L451
967
+ *
968
+ * @param $json
969
+ *
970
+ * @return mixed|WP_Error
971
+ */
972
+ public function smartcalcs_cache_request( $json ) {
973
+ $cache_key = 'tj_tax_' . hash( 'md5', $json );
974
+ $response = get_transient( $cache_key );
975
+
976
+ if ( false === $response ) {
977
+ $response = $this->smartcalcs_request( $json );
978
+
979
+ if ( 200 == wp_remote_retrieve_response_code( $response ) ) {
980
+ set_transient( $cache_key, $response, $this->cache_time );
981
+ }
982
+ }
983
+
984
+ return $response;
985
+ }
986
+
987
+ /**
988
+ * Make a TaxJar SmartCalcs API request through the WCS proxy.
989
+ *
990
+ * Modified from TaxJar's plugin.
991
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/82bf7c58/includes/class-wc-taxjar-integration.php#L440
992
+ *
993
+ * @param $json
994
+ *
995
+ * @return array|WP_Error
996
+ */
997
+ public function smartcalcs_request( $json ) {
998
+ $path = trailingslashit( self::PROXY_PATH ) . 'taxes';
999
+
1000
+ $this->_log( 'Requesting: ' . $path . ' - ' . $json );
1001
+
1002
+ $response = $this->api_client->proxy_request( $path, array(
1003
+ 'method' => 'POST',
1004
+ 'headers' => array(
1005
+ 'Content-Type' => 'application/json',
1006
+ ),
1007
+ 'body' => $json,
1008
+ ) );
1009
+
1010
+ if ( is_wp_error( $response ) ) {
1011
+ $this->_error( 'Error retrieving the tax rates. Received (' . $response->get_error_code() . '): ' . $response->get_error_message() );
1012
+ } elseif ( 200 == $response['response']['code'] ) {
1013
+ return $response;
1014
+ } else {
1015
+ $this->_error( 'Error retrieving the tax rates. Received (' . $response['response']['code'] . '): ' . $response['body'] );
1016
+ }
1017
+ }
1018
+
1019
+ /**
1020
+ * Exports existing tax rates to a CSV and clears the table.
1021
+ *
1022
+ * Ported from TaxJar's plugin.
1023
+ * See: https://github.com/taxjar/taxjar-woocommerce-plugin/blob/42cd4cd0/taxjar-woocommerce.php#L75
1024
+ */
1025
+ public function backup_existing_tax_rates() {
1026
+ global $wpdb;
1027
+
1028
+ // Export Tax Rates
1029
+ $rates = $wpdb->get_results( $wpdb->prepare(
1030
+ "SELECT * FROM {$wpdb->prefix}woocommerce_tax_rates
1031
+ ORDER BY tax_rate_order
1032
+ LIMIT %d, %d
1033
+ ",
1034
+ 0,
1035
+ 10000
1036
+ ) );
1037
+
1038
+ ob_start();
1039
+ $header =
1040
+ __( 'Country Code', 'woocommerce' ) . ',' .
1041
+ __( 'State Code', 'woocommerce' ) . ',' .
1042
+ __( 'ZIP/Postcode', 'woocommerce' ) . ',' .
1043
+ __( 'City', 'woocommerce' ) . ',' .
1044
+ __( 'Rate %', 'woocommerce' ) . ',' .
1045
+ __( 'Tax Name', 'woocommerce' ) . ',' .
1046
+ __( 'Priority', 'woocommerce' ) . ',' .
1047
+ __( 'Compound', 'woocommerce' ) . ',' .
1048
+ __( 'Shipping', 'woocommerce' ) . ',' .
1049
+ __( 'Tax Class', 'woocommerce' ) . "\n";
1050
+
1051
+ echo $header;
1052
+
1053
+ foreach ( $rates as $rate ) {
1054
+ if ( $rate->tax_rate_country ) {
1055
+ echo esc_attr( $rate->tax_rate_country );
1056
+ } else {
1057
+ echo '*';
1058
+ }
1059
+
1060
+ echo ',';
1061
+
1062
+ if ( $rate->tax_rate_state ) {
1063
+ echo esc_attr( $rate->tax_rate_state );
1064
+ } else {
1065
+ echo '*';
1066
+ }
1067
+
1068
+ echo ',';
1069
+
1070
+ $locations = $wpdb->get_col( $wpdb->prepare( "SELECT location_code FROM {$wpdb->prefix}woocommerce_tax_rate_locations WHERE location_type='postcode' AND tax_rate_id = %d ORDER BY location_code", $rate->tax_rate_id ) );
1071
+
1072
+ if ( $locations ) {
1073
+ echo esc_attr( implode( '; ', $locations ) );
1074
+ } else {
1075
+ echo '*';
1076
+ }
1077
+
1078
+ echo ',';
1079
+
1080
+ $locations = $wpdb->get_col( $wpdb->prepare( "SELECT location_code FROM {$wpdb->prefix}woocommerce_tax_rate_locations WHERE location_type='city' AND tax_rate_id = %d ORDER BY location_code", $rate->tax_rate_id ) );
1081
+ if ( $locations ) {
1082
+ echo esc_attr( implode( '; ', $locations ) );
1083
+ } else {
1084
+ echo '*';
1085
+ }
1086
+
1087
+ echo ',';
1088
+
1089
+ if ( $rate->tax_rate ) {
1090
+ echo esc_attr( $rate->tax_rate );
1091
+ } else {
1092
+ echo '0';
1093
+ }
1094
+
1095
+ echo ',';
1096
+
1097
+ if ( $rate->tax_rate_name ) {
1098
+ echo esc_attr( $rate->tax_rate_name );
1099
+ } else {
1100
+ echo '*';
1101
+ }
1102
+
1103
+ echo ',';
1104
+
1105
+ if ( $rate->tax_rate_priority ) {
1106
+ echo esc_attr( $rate->tax_rate_priority );
1107
+ } else {
1108
+ echo '1';
1109
+ }
1110
+
1111
+ echo ',';
1112
+
1113
+ if ( $rate->tax_rate_compound ) {
1114
+ echo esc_attr( $rate->tax_rate_compound );
1115
+ } else {
1116
+ echo '0';
1117
+ }
1118
+
1119
+ echo ',';
1120
+
1121
+ if ( $rate->tax_rate_shipping ) {
1122
+ echo esc_attr( $rate->tax_rate_shipping );
1123
+ } else {
1124
+ echo '0';
1125
+ }
1126
+
1127
+ echo ',';
1128
+
1129
+ echo "\n";
1130
+ } // End foreach().
1131
+
1132
+ $csv = ob_get_contents();
1133
+ ob_end_clean();
1134
+ $upload_dir = wp_upload_dir();
1135
+ file_put_contents( $upload_dir['basedir'] . '/taxjar-wc_tax_rates-' . date( 'm-d-Y' ) . '-' . time() . '.csv', $csv );
1136
+
1137
+ // Delete all tax rates
1138
+ $wpdb->query( 'TRUNCATE ' . $wpdb->prefix . 'woocommerce_tax_rates' );
1139
+ $wpdb->query( 'TRUNCATE ' . $wpdb->prefix . 'woocommerce_tax_rate_locations' );
1140
+ }
1141
+
1142
+ /**
1143
+ * Checks if currently on the WooCommerce new order page
1144
+ *
1145
+ * @return boolean
1146
+ */
1147
+ public function on_order_page() {
1148
+ global $pagenow;
1149
+ return ( in_array( $pagenow, array( 'post-new.php' ) ) && isset( $_GET['post_type'] ) && 'shop_order' == $_GET['post_type'] );
1150
+ }
1151
+
1152
+ /**
1153
+ * Admin New Order Assets
1154
+ */
1155
+ public function load_taxjar_admin_new_order_assets() {
1156
+ if ( ! $this->on_order_page() ) {
1157
+ return;
1158
+ }
1159
+ // Load Javascript for WooCommerce new order page
1160
+ wp_register_script( 'wc-taxjar-order', $this->wc_connect_base_url . 'woocommerce-services-new-order-taxjar.js' );
1161
+ wp_enqueue_script( 'wc-taxjar-order' , array( 'jquery' ) );
1162
+ }
1163
+ }
trunk/classes/class-wc-connect-tracks.php ADDED
@@ -0,0 +1,125 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // No direct access please
4
+ if ( ! defined( 'ABSPATH' ) ) {
5
+ exit;
6
+ }
7
+
8
+ if ( ! class_exists( 'WC_Connect_Tracks' ) ) {
9
+
10
+ class WC_Connect_Tracks {
11
+ static $product_name = 'woocommerceconnect';
12
+
13
+ /**
14
+ * @var WC_Connect_Logger
15
+ */
16
+ protected $logger;
17
+
18
+ public function __construct( WC_Connect_Logger $logger, $plugin_file ) {
19
+ $this->logger = $logger;
20
+ $this->plugin_file = $plugin_file;
21
+ }
22
+
23
+ public function init() {
24
+ add_action( 'wc_connect_shipping_zone_method_added', array( $this, 'shipping_zone_method_added' ), 10, 3 );
25
+ add_action( 'wc_connect_shipping_zone_method_deleted', array( $this, 'shipping_zone_method_deleted' ), 10, 3 );
26
+ add_action( 'wc_connect_shipping_zone_method_status_toggled', array( $this, 'shipping_zone_method_status_toggled' ), 10, 4 );
27
+ add_action( 'wc_connect_saved_service_settings', array( $this, 'saved_service_settings' ), 10, 3 );
28
+ register_deactivation_hook( $this->plugin_file, array( $this, 'opted_out' ) );
29
+ }
30
+
31
+ public function opted_in( $source = null ) {
32
+ if ( is_null( $source ) ) {
33
+ $this->record_user_event( 'opted_in' );
34
+ } else {
35
+ $this->record_user_event( 'opted_in', compact( 'source' ) );
36
+ }
37
+ }
38
+
39
+ public function opted_out() {
40
+ $this->record_user_event( 'opted_out' );
41
+ }
42
+
43
+ public function shipping_zone_method_added( $instance_id, $service_id ) {
44
+ $this->record_user_event( 'shipping_zone_method_added' );
45
+ $this->record_user_event( 'shipping_zone_' . $service_id . '_added' );
46
+ }
47
+
48
+ public function shipping_zone_method_deleted( $instance_id, $service_id ) {
49
+ $this->record_user_event( 'shipping_zone_method_deleted' );
50
+ $this->record_user_event( 'shipping_zone_' . $service_id . '_deleted' );
51
+ }
52
+
53
+ public function shipping_zone_method_status_toggled( $instance_id, $service_id, $zone_id, $enabled ) {
54
+ if ( $enabled ) {
55
+ $this->record_user_event( 'shipping_zone_method_enabled' );
56
+ $this->record_user_event( 'shipping_zone_' . $service_id . '_enabled' );
57
+ } else {
58
+ $this->record_user_event( 'shipping_zone_method_disabled' );
59
+ $this->record_user_event( 'shipping_zone_' . $service_id . '_disabled' );
60
+ }
61
+ }
62
+
63
+ public function saved_service_settings( $service_id ) {
64
+ $this->record_user_event( 'saved_service_settings' );
65
+ $this->record_user_event( 'saved_' . $service_id . '_settings' );
66
+ }
67
+
68
+ public function record_user_event( $event_type, $data = array() ) {
69
+ if ( ! function_exists( 'jetpack_tracks_record_event' ) && ! class_exists( 'Automattic\\Jetpack\\Tracking' ) ) {
70
+ $this->debug( 'Error. jetpack_tracks_record_event is not defined.' );
71
+ return;
72
+ }
73
+ $user = wp_get_current_user();
74
+ $site_url = get_option( 'siteurl' );
75
+
76
+ $wcs_version = WC_Connect_Loader::get_wcs_version();
77
+
78
+ // Check for WooCommerce
79
+ $wc_version = 'unavailable';
80
+ if ( function_exists( 'WC' ) ) {
81
+ $wc_version = WC()->version;
82
+ }
83
+
84
+ // Check for Jetpack
85
+ $jp_version = 'unavailable';
86
+ if ( defined( 'JETPACK__VERSION' ) ) {
87
+ $jp_version = JETPACK__VERSION;
88
+ }
89
+ $is_atomic = WC_Connect_Jetpack::is_atomic_site();
90
+
91
+ $jetpack_blog_id = -1;
92
+ if ( class_exists( 'Jetpack_Options' ) && method_exists( 'Jetpack_Options', 'get_option' ) ) {
93
+ $jetpack_blog_id = Jetpack_Options::get_option( 'id' );
94
+ }
95
+
96
+ if ( ! is_array( $data ) ) {
97
+ $data = array();
98
+ }
99
+
100
+ $data['_via_ua'] = isset( $_SERVER['HTTP_USER_AGENT'] ) ? $_SERVER['HTTP_USER_AGENT'] : '';
101
+ $data['_via_ip'] = isset( $_SERVER['REMOTE_ADDR'] ) ? $_SERVER['REMOTE_ADDR'] : '';
102
+ $data['_lg'] = isset( $_SERVER['HTTP_ACCEPT_LANGUAGE'] ) ? $_SERVER['HTTP_ACCEPT_LANGUAGE'] : '';
103
+ $data['blog_url'] = $site_url;
104
+ $data['blog_id'] = $jetpack_blog_id;
105
+ $data['wcs_version'] = $wcs_version;
106
+ $data['jetpack_version'] = $jp_version;
107
+ $data['is_atomic'] = $is_atomic;
108
+ $data['wc_version'] = $wc_version;
109
+ $data['wp_version'] = get_bloginfo( 'version' );
110
+
111
+ $event_type = self::$product_name . '_' . $event_type;
112
+
113
+ $this->debug( 'Tracked the following event: ' . $event_type );
114
+ WC_Connect_Jetpack::tracks_record_event( $user, $event_type, $data );
115
+ }
116
+
117
+ protected function debug( $message ) {
118
+ if ( ! is_null( $this->logger ) ) {
119
+ $this->logger->log( $message );
120
+ }
121
+ }
122
+
123
+ }
124
+
125
+ }
trunk/classes/class-wc-rest-connect-account-settings-controller.php ADDED
@@ -0,0 +1,101 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Account_Settings_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Account_Settings_Controller extends WC_REST_Connect_Base_Controller {
12
+
13
+ protected $rest_base = 'connect/account/settings';
14
+
15
+ /*
16
+ * @var WC_Connect_Payment_Methods_Store
17
+ */
18
+ protected $payment_methods_store;
19
+
20
+ public function __construct( WC_Connect_API_Client $api_client, WC_Connect_Service_Settings_Store $settings_store, WC_Connect_Logger $logger, WC_Connect_Payment_Methods_Store $payment_methods_store ) {
21
+ parent::__construct( $api_client, $settings_store, $logger );
22
+ $this->payment_methods_store = $payment_methods_store;
23
+ }
24
+
25
+ public function get() {
26
+ // Always get a fresh list of payment methods when hitting this endpoint
27
+ $payment_methods_warning = false;
28
+ $payment_methods_success = $this->payment_methods_store->fetch_payment_methods_from_connect_server();
29
+
30
+ if ( ! $payment_methods_success ) {
31
+ $payment_methods_warning = __( 'There was a problem updating your saved credit cards.', 'woocommerce-services' );
32
+ }
33
+
34
+ $master_user = WC_Connect_Jetpack::get_master_user();
35
+ if ( is_a( $master_user, 'WP_User' ) ) {
36
+ $master_user_name = $master_user->display_name;
37
+ $master_user_login = $master_user->user_login;
38
+
39
+ $connected_data = WC_Connect_Jetpack::get_connected_user_data( $master_user->ID );
40
+ $master_user_email = $connected_data['email'];
41
+ $master_user_wpcom_login = $connected_data['login'];
42
+ } else {
43
+ $master_user_name = '';
44
+ $master_user_login = '';
45
+
46
+ $master_user_email = '';
47
+ $master_user_wpcom_login = '';
48
+ }
49
+
50
+ $last_box_id = get_user_meta( get_current_user_id(), 'wc_connect_last_box_id', true );
51
+ $last_box_id = $last_box_id === "individual" ? "" : $last_box_id;
52
+
53
+ return new WP_REST_Response( array(
54
+ 'success' => true,
55
+ 'storeOptions' => $this->settings_store->get_store_options(),
56
+ 'formData' => $this->settings_store->get_account_settings(),
57
+ 'formMeta' => array(
58
+ 'can_manage_payments' => $this->settings_store->can_user_manage_payment_methods(),
59
+ 'can_edit_settings' => true,
60
+ 'master_user_name' => $master_user_name,
61
+ 'master_user_login' => $master_user_login,
62
+ 'master_user_wpcom_login' => $master_user_wpcom_login,
63
+ 'master_user_email' => $master_user_email,
64
+ 'payment_methods' => $this->payment_methods_store->get_payment_methods(),
65
+ 'warnings' => array( 'payment_methods' => $payment_methods_warning ),
66
+ ),
67
+ 'userMeta' => array(
68
+ 'last_box_id' => $last_box_id,
69
+ ),
70
+ ), 200 );
71
+ }
72
+
73
+ public function post( $request ) {
74
+ $settings = $request->get_json_params();
75
+
76
+ if ( ! $this->settings_store->can_user_manage_payment_methods() ) {
77
+ // Ignore the user-provided payment method ID if they don't have permission to change it
78
+ $old_settings = $this->settings_store->get_account_settings();
79
+ $settings['selected_payment_method_id'] = $old_settings['selected_payment_method_id'];
80
+ }
81
+
82
+ $result = $this->settings_store->update_account_settings( $settings );
83
+
84
+ if ( is_wp_error( $result ) ) {
85
+ $error = new WP_Error( 'save_failed',
86
+ sprintf(
87
+ __( 'Unable to update settings. %s', 'woocommerce-services' ),
88
+ $result->get_error_message()
89
+ ),
90
+ array_merge(
91
+ array( 'status' => 400 ),
92
+ $result->get_error_data()
93
+ )
94
+ );
95
+ $this->logger->log( $error, __CLASS__ );
96
+ return $error;
97
+ }
98
+
99
+ return new WP_REST_Response( array( 'success' => true ), 200 );
100
+ }
101
+ }
trunk/classes/class-wc-rest-connect-address-normalization-controller.php ADDED
@@ -0,0 +1,70 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Address_Normalization_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Address_Normalization_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/normalize-address';
13
+
14
+ public function post( $request ) {
15
+ $data = $request->get_json_params();
16
+ $address = $data[ 'address' ];
17
+ $name = $address[ 'name' ];
18
+ $company = $address[ 'company' ];
19
+ $phone = $address[ 'phone' ];
20
+
21
+ unset( $address[ 'name' ], $address[ 'company' ], $address[ 'phone' ] );
22
+
23
+ $body = array(
24
+ 'destination' => $address,
25
+ );
26
+ $response = $this->api_client->send_address_normalization_request( $body );
27
+
28
+ if ( is_wp_error( $response ) ) {
29
+ $error = new WP_Error(
30
+ $response->get_error_code(),
31
+ $response->get_error_message(),
32
+ array( 'message' => $response->get_error_message() )
33
+ );
34
+ $this->logger->log( $error, __CLASS__ );
35
+ return $error;
36
+ }
37
+
38
+ if ( isset( $response->field_errors ) ) {
39
+ $this->logger->log( 'Address validation errors: ' . implode( '; ', array_values( (array) $response->field_errors ) ), __CLASS__ );
40
+ return array(
41
+ 'success' => true,
42
+ 'field_errors' => $response->field_errors,
43
+ );
44
+ }
45
+
46
+ $response->normalized->name = $name;
47
+ $response->normalized->company = $company;
48
+ $response->normalized->phone = $phone;
49
+ $is_trivial_normalization = isset( $response->is_trivial_normalization ) ? $response->is_trivial_normalization : false;
50
+
51
+ return array(
52
+ 'success' => true,
53
+ 'normalized' => $response->normalized,
54
+ 'is_trivial_normalization' => $is_trivial_normalization,
55
+ );
56
+ }
57
+
58
+ /**
59
+ * Validate the requester's permissions
60
+ */
61
+ public function check_permission( $request ) {
62
+ $data = $request->get_json_params();
63
+
64
+ if ( 'origin' === $data['type'] ) {
65
+ return current_user_can( 'manage_woocommerce' ); // Only an admin can normalize the origin address
66
+ }
67
+
68
+ return true; // non-authenticated service for the 'destination' address
69
+ }
70
+ }
trunk/classes/class-wc-rest-connect-base-controller.php ADDED
@@ -0,0 +1,110 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Base_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ abstract class WC_REST_Connect_Base_Controller extends WP_REST_Controller {
12
+
13
+ /**
14
+ * Endpoint namespace.
15
+ *
16
+ * @var string
17
+ */
18
+ protected $namespace = 'wc/v1';
19
+
20
+ /**
21
+ * @var WC_Connect_API_Client
22
+ */
23
+ protected $api_client;
24
+
25
+ /**
26
+ * @var WC_Connect_Service_Settings_Store
27
+ */
28
+ protected $settings_store;
29
+
30
+ /**
31
+ * @var WC_Connect_Logger
32
+ */
33
+ protected $logger;
34
+
35
+ public function __construct( WC_Connect_API_Client $api_client, WC_Connect_Service_Settings_Store $settings_store, WC_Connect_Logger $logger ) {
36
+ $this->api_client = $api_client;
37
+ $this->settings_store = $settings_store;
38
+ $this->logger = $logger;
39
+ }
40
+
41
+ public function register_routes() {
42
+ if ( method_exists( $this, 'get' ) ) {
43
+ register_rest_route( $this->namespace, '/' . $this->rest_base, array(
44
+ array(
45
+ 'methods' => 'GET',
46
+ 'callback' => array( $this, 'get_internal' ),
47
+ 'permission_callback' => array( $this, 'check_permission' ),
48
+ ),
49
+ ) );
50
+ }
51
+ if ( method_exists( $this, 'post' ) ) {
52
+ register_rest_route( $this->namespace, '/' . $this->rest_base, array(
53
+ array(
54
+ 'methods' => 'POST',
55
+ 'callback' => array( $this, 'post_internal' ),
56
+ 'permission_callback' => array( $this, 'check_permission' ),
57
+ ),
58
+ ) );
59
+ }
60
+ }
61
+
62
+ /**
63
+ * Consolidate cache prevention mechanisms.
64
+ */
65
+ public function prevent_route_caching() {
66
+ if ( ! defined( 'DONOTCACHEPAGE' ) ) {
67
+ define( 'DONOTCACHEPAGE', true ); // Play nice with WP-Super-Cache
68
+ }
69
+
70
+ // Prevent our REST API endpoint responses from being added to browser cache
71
+ add_filter( 'rest_post_dispatch', array( $this, 'send_nocache_header' ), PHP_INT_MAX, 2 );
72
+ }
73
+
74
+ /**
75
+ * Send a no-cache header for WCS REST API responses. Prompted by cache issues
76
+ * on the Pantheon hosting platform.
77
+ *
78
+ * See: https://pantheon.io/docs/cache-control/
79
+ *
80
+ * @param WP_REST_Response $response
81
+ * @param WP_REST_Server $server
82
+ *
83
+ * @return WP_REST_Response passthrough $response parameter
84
+ */
85
+ public function send_nocache_header( $response, $server ) {
86
+ $server->send_header( 'Cache-Control', 'no-cache, must-revalidate, max-age=0' );
87
+
88
+ return $response;
89
+ }
90
+
91
+ public function get_internal( $request ) {
92
+ $this->prevent_route_caching();
93
+
94
+ return $this->get( $request );
95
+ }
96
+
97
+ public function post_internal( $request ) {
98
+ $this->prevent_route_caching();
99
+
100
+ return $this->post( $request );
101
+ }
102
+
103
+ /**
104
+ * Validate the requester's permissions
105
+ */
106
+ public function check_permission( $request ) {
107
+ return current_user_can( 'manage_woocommerce' );
108
+ }
109
+
110
+ }
trunk/classes/class-wc-rest-connect-packages-controller.php ADDED
@@ -0,0 +1,48 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Packages_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Packages_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/packages';
13
+
14
+ /*
15
+ * @var WC_Connect_Service_Schemas_Store
16
+ */
17
+ protected $service_schemas_store;
18
+
19
+ public function __construct( WC_Connect_API_Client $api_client, WC_Connect_Service_Settings_Store $settings_store, WC_Connect_Logger $logger, WC_Connect_Service_Schemas_Store $service_schemas_store ) {
20
+ parent::__construct( $api_client, $settings_store, $logger );
21
+ $this->service_schemas_store = $service_schemas_store;
22
+ }
23
+
24
+ public function get() {
25
+ return new WP_REST_Response( array(
26
+ 'success' => true,
27
+ 'storeOptions' => $this->settings_store->get_store_options(),
28
+ 'formSchema' => array(
29
+ 'custom' => $this->service_schemas_store->get_packages_schema(),
30
+ 'predefined' => $this->service_schemas_store->get_predefined_packages_schema()
31
+ ),
32
+ 'formData' => array(
33
+ 'custom' => $this->settings_store->get_packages(),
34
+ 'predefined' => $this->settings_store->get_predefined_packages()
35
+ )
36
+ ), 200 );
37
+ }
38
+
39
+ public function post( $request ) {
40
+ $packages = $request->get_json_params();
41
+
42
+ $this->settings_store->update_packages( $packages[ 'custom' ] );
43
+ $this->settings_store->update_predefined_packages( $packages[ 'predefined' ] );
44
+
45
+ return new WP_REST_Response( array( 'success' => true ), 200 );
46
+ }
47
+
48
+ }
trunk/classes/class-wc-rest-connect-self-help-controller.php ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Self_Help_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Self_Help_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/self-help';
13
+
14
+ public function post( $request ) {
15
+ $settings = $request->get_json_params();
16
+
17
+ if (
18
+ empty( $settings )
19
+ || ! array_key_exists( 'wcc_debug_on', $settings )
20
+ || ! array_key_exists( 'wcc_logging_on', $settings )
21
+ ) {
22
+ $error = new WP_Error( 'bad_form_data',
23
+ __( 'Unable to update settings. The form data could not be read.', 'woocommerce-services' ),
24
+ array( 'status' => 400 )
25
+ );
26
+ $this->logger->log( $error, __CLASS__ );
27
+ return $error;
28
+ }
29
+
30
+ if ( 1 == $settings['wcc_logging_on'] ) {
31
+ $this->logger->enable_logging();
32
+ } else {
33
+ $this->logger->disable_logging();
34
+ }
35
+
36
+ if ( 1 == $settings['wcc_debug_on'] ) {
37
+ $this->logger->enable_debug();
38
+ } else {
39
+ $this->logger->disable_debug();
40
+ }
41
+
42
+ return new WP_REST_Response( array( 'success' => true ), 200 );
43
+ }
44
+
45
+ }
trunk/classes/class-wc-rest-connect-services-controller.php ADDED
@@ -0,0 +1,94 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Services_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Services_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/services/(?P<id>[a-z_]+)\/(?P<instance>[\d]+)';
13
+
14
+ /**
15
+ * @var WC_Connect_Service_Schemas_Store
16
+ */
17
+ protected $service_schemas_store;
18
+
19
+ public function __construct(
20
+ WC_Connect_API_Client $api_client,
21
+ WC_Connect_Service_Settings_Store $settings_store,
22
+ WC_Connect_Logger $logger,
23
+ WC_Connect_Service_Schemas_Store $schemas_store
24
+ ) {
25
+ parent::__construct( $api_client, $settings_store, $logger );
26
+ $this->service_schemas_store = $schemas_store;
27
+ }
28
+
29
+ public function get( $request ) {
30
+ $method_id = $request[ 'id' ];
31
+ $instance_id = isset( $request[ 'instance' ] ) ? $request[ 'instance' ] : false;
32
+
33
+ $service_schema = $this->service_schemas_store->get_service_schema_by_id_or_instance_id( $instance_id
34
+ ? $instance_id
35
+ : $method_id );
36
+
37
+ if ( ! $service_schema ) {
38
+ return new WP_Error( 'schemas_not_found', __( 'Service schemas were not loaded', 'woocommerce-services' ), array( 'status' => 500 ) );
39
+ }
40
+
41
+ $payload = apply_filters( 'wc_connect_shipping_service_settings', array(
42
+ 'success' => true,
43
+ ), $method_id, $instance_id );
44
+
45
+ return new WP_REST_Response( $payload, 200 );
46
+ }
47
+
48
+ /**
49
+ * Attempts to update the settings on a particular service and instance
50
+ */
51
+ public function post( $request ) {
52
+ $request_params = $request->get_params();
53
+
54
+ $id = array_key_exists( 'id', $request_params ) ? $request_params['id'] : '';
55
+ $instance = array_key_exists( 'instance', $request_params ) ? absint( $request_params['instance'] ) : false;
56
+
57
+ if ( empty( $id ) ) {
58
+ $error = new WP_Error( 'service_id_missing',
59
+ __( 'Unable to update service settings. Form data is missing service ID.', 'woocommerce-services' ),
60
+ array( 'status' => 400 )
61
+ );
62
+ $this->logger->log( $error, __CLASS__ );
63
+ return $error;
64
+ }
65
+
66
+ $settings = ( object ) $request->get_json_params();
67
+
68
+ if ( empty( $settings ) ) {
69
+ $error = new WP_Error( 'bad_form_data',
70
+ __( 'Unable to update service settings. The form data could not be read.', 'woocommerce-services' ),
71
+ array( 'status' => 400 )
72
+ );
73
+ $this->logger->log( $error, __CLASS__ );
74
+ return $error;
75
+ }
76
+
77
+ $validation_result = $this->settings_store->validate_and_possibly_update_settings( $settings, $id, $instance );
78
+
79
+ if ( is_wp_error( $validation_result ) ) {
80
+ $error = new WP_Error( 'validation_failed',
81
+ sprintf(
82
+ __( 'Unable to update service settings. Validation failed. %s', 'woocommerce-services' ),
83
+ $validation_result->get_error_message()
84
+ ),
85
+ array( 'status' => 400 )
86
+ );
87
+ $this->logger->log( $error, __CLASS__ );
88
+ return $error;
89
+ }
90
+
91
+ return new WP_REST_Response( array( 'success' => true ), 200 );
92
+ }
93
+
94
+ }
trunk/classes/class-wc-rest-connect-shipping-label-controller.php ADDED
@@ -0,0 +1,133 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Shipping_Label_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Shipping_Label_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/label/(?P<order_id>\d+)';
13
+
14
+ /*
15
+ * @var WC_Connect_Shipping_Label
16
+ */
17
+ protected $shipping_label;
18
+
19
+ public function __construct( WC_Connect_API_Client $api_client, WC_Connect_Service_Settings_Store $settings_store, WC_Connect_Logger $logger, WC_Connect_Shipping_Label $shipping_label ) {
20
+ parent::__construct( $api_client, $settings_store, $logger );
21
+ $this->shipping_label = $shipping_label;
22
+ }
23
+
24
+ public function get( $request ) {
25
+ $order_id = $request[ 'order_id' ];
26
+ $payload = $this->shipping_label->get_label_payload( $order_id );
27
+ if ( ! $payload ) {
28
+ return new WP_Error( 'not_found', __( 'Order not found', 'woocommerce-services' ), array( 'status' => 404 ) );
29
+ }
30
+ $payload[ 'success' ] = true;
31
+ return new WP_REST_Response( $payload, 200 );
32
+ }
33
+
34
+ public function post( $request ) {
35
+ $settings = $request->get_json_params();
36
+ $order_id = $request[ 'order_id' ];
37
+ $settings[ 'order_id' ] = $order_id;
38
+
39
+ if ( empty( $settings[ 'payment_method_id' ] ) || ! $this->settings_store->can_user_manage_payment_methods() ) {
40
+ $settings[ 'payment_method_id' ] = $this->settings_store->get_selected_payment_method_id();
41
+ } else {
42
+ $this->settings_store->set_selected_payment_method_id( $settings[ 'payment_method_id' ] );
43
+ }
44
+
45
+ $last_box_id = '';
46
+ $service_names = array();
47
+ foreach ( $settings[ 'packages' ] as $index => $package ) {
48
+ $service_names[] = $package[ 'service_name' ];
49
+ unset( $package[ 'service_name' ] );
50
+ $settings[ 'packages' ][ $index ] = $package;
51
+
52
+ if ( empty( $last_box_id ) && ! empty( $package['box_id'] ) ) {
53
+ $last_box_id = $package['box_id'];
54
+ }
55
+ }
56
+
57
+ if ( ! empty( $last_box_id ) && $last_box_id !== "individual" ) {
58
+ update_user_meta( get_current_user_id(), 'wc_connect_last_box_id', $last_box_id );
59
+ }
60
+
61
+ $response = $this->api_client->send_shipping_label_request( $settings );
62
+
63
+ if ( is_wp_error( $response ) ) {
64
+ $error = new WP_Error(
65
+ $response->get_error_code(),
66
+ $response->get_error_message(),
67
+ array( 'message' => $response->get_error_message() )
68
+ );
69
+ $this->logger->log( $error, __CLASS__ );
70
+ return $error;
71
+ }
72
+
73
+ $label_ids = array();
74
+ $purchased_labels_meta = array();
75
+ $package_lookup = $this->settings_store->get_package_lookup();
76
+ foreach ( $response->labels as $index => $label_data ) {
77
+ if ( isset( $label_data->error ) ) {
78
+ $error = new WP_Error(
79
+ $label_data->error->code,
80
+ $label_data->error->message,
81
+ array( 'message' => $label_data->error->message )
82
+ );
83
+ $this->logger->log( $error, __CLASS__ );
84
+ return $error;
85
+ }
86
+ $label_ids[] = $label_data->label->label_id;
87
+
88
+ $label_meta = array(
89
+ 'label_id' => $label_data->label->label_id,
90
+ 'tracking' => $label_data->label->tracking_id,
91
+ 'refundable_amount' => $label_data->label->refundable_amount,
92
+ 'created' => $label_data->label->created,
93
+ 'carrier_id' => $label_data->label->carrier_id,
94
+ 'service_name' => $service_names[ $index ],
95
+ 'status' => $label_data->label->status,
96
+ );
97
+
98
+ $package = $settings[ 'packages' ][ $index ];
99
+ $box_id = $package[ 'box_id' ];
100
+ if ( 'individual' === $box_id ) {
101
+ $label_meta[ 'package_name' ] = __( 'Individual packaging', 'woocommerce-services' );
102
+ } else if ( isset( $package_lookup[ $box_id ] ) ) {
103
+ $label_meta[ 'package_name' ] = $package_lookup[ $box_id ][ 'name' ];
104
+ } else {
105
+ $label_meta[ 'package_name' ] = __( 'Unknown package', 'woocommerce-services' );
106
+ }
107
+
108
+ $product_names = array();
109
+ foreach ( $package[ 'products' ] as $product_id ) {
110
+ $product = wc_get_product( $product_id );
111
+
112
+ if ( $product ) {
113
+ $product_names[] = $product->get_title();
114
+ } else {
115
+ $order = wc_get_order( $order_id );
116
+ $product_names[] = WC_Connect_Compatibility::instance()->get_product_name_from_order( $product_id, $order );
117
+ }
118
+ }
119
+
120
+ $label_meta[ 'product_names' ] = $product_names;
121
+
122
+ array_unshift( $purchased_labels_meta, $label_meta );
123
+ }
124
+
125
+ $this->settings_store->add_labels_to_order( $order_id, $purchased_labels_meta );
126
+
127
+ return array(
128
+ 'labels' => $purchased_labels_meta,
129
+ 'success' => true,
130
+ );
131
+ }
132
+
133
+ }
trunk/classes/class-wc-rest-connect-shipping-label-preview-controller.php ADDED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Shipping_Label_Preview_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Shipping_Label_Preview_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/label/preview';
13
+
14
+ public function get( $request ) {
15
+ $raw_params = $request->get_params();
16
+ $params = array();
17
+
18
+ $params[ 'paper_size' ] = $raw_params[ 'paper_size' ];
19
+ $this->settings_store->set_preferred_paper_size( $params[ 'paper_size' ] );
20
+ $params[ 'carrier' ] = 'usps';
21
+ $params[ 'labels' ] = array();
22
+ $captions = empty( $raw_params[ 'caption_csv' ] ) ? array() : explode( ',', $raw_params[ 'caption_csv' ] );
23
+
24
+ foreach ( $captions as $caption ) {
25
+ $params[ 'labels' ][] = array( 'caption' => urldecode( $caption ) );
26
+ }
27
+
28
+ $raw_response = $this->api_client->get_labels_preview_pdf( $params );
29
+
30
+ if ( is_wp_error( $raw_response ) ) {
31
+ $this->logger->log( $raw_response, __CLASS__ );
32
+ return $raw_response;
33
+ }
34
+
35
+ header( 'content-type: ' . $raw_response[ 'headers' ][ 'content-type' ] );
36
+ echo $raw_response[ 'body' ];
37
+ die();
38
+ }
39
+
40
+ }
trunk/classes/class-wc-rest-connect-shipping-label-print-controller.php ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Shipping_Label_Print_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Shipping_Label_Print_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/label/print';
13
+
14
+ public function get( $request ) {
15
+ $raw_params = $request->get_params();
16
+ $params = array();
17
+
18
+ $params[ 'paper_size' ] = $raw_params[ 'paper_size' ];
19
+ $this->settings_store->set_preferred_paper_size( $params[ 'paper_size' ] );
20
+
21
+ $label_ids = ! empty( $raw_params[ 'label_id_csv' ] ) ? explode( ',', $raw_params[ 'label_id_csv' ] ) : array();
22
+ $n_label_ids = count( $label_ids );
23
+ $captions = ! empty( $raw_params[ 'caption_csv' ] ) ? explode( ',', $raw_params[ 'caption_csv' ] ) : array();
24
+ $n_captions = count( $captions );
25
+ // Either there are the same number of captions as labels, or no captions at all
26
+ if ( ! $n_label_ids || ( $n_captions && $n_captions !== $n_label_ids ) ) {
27
+ $message = __( 'Invalid PDF request.', 'woocommerce-services' );
28
+ $error = new WP_Error(
29
+ 'invalid_pdf_request',
30
+ $message,
31
+ array(
32
+ 'message' => $message,
33
+ 'status' => 400
34
+ )
35
+ );
36
+ $this->logger->log( $error, __CLASS__ );
37
+ return $error;
38
+ }
39
+ $params[ 'labels' ] = array();
40
+ for ( $i = 0; $i < $n_label_ids; $i++ ) {
41
+ $params[ 'labels' ][ $i ] = array();
42
+ $params[ 'labels' ][ $i ][ 'label_id' ] = (int) $label_ids[ $i ];
43
+
44
+ if ( $n_captions ) {
45
+ $params[ 'labels' ][ $i ][ 'caption' ] = urldecode( $captions[ $i ] );
46
+ }
47
+ }
48
+
49
+ $raw_response = $this->api_client->get_labels_print_pdf( $params );
50
+
51
+ if ( is_wp_error( $raw_response ) ) {
52
+ $this->logger->log( $raw_response, __CLASS__ );
53
+ return $raw_response;
54
+ }
55
+
56
+ if ( isset( $raw_params[ 'json' ] ) && $raw_params[ 'json' ] ) {
57
+ return array(
58
+ 'mimeType' => $raw_response[ 'headers' ][ 'content-type' ],
59
+ 'b64Content' => base64_encode( $raw_response[ 'body' ] ),
60
+ 'success' => true,
61
+ );
62
+ } else {
63
+ header( 'content-type: ' . $raw_response[ 'headers' ][ 'content-type' ] );
64
+ echo $raw_response[ 'body' ];
65
+ die();
66
+ }
67
+ }
68
+
69
+ }
trunk/classes/class-wc-rest-connect-shipping-label-refund-controller.php ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Shipping_Label_Refund_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Shipping_Label_Refund_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/label/(?P<order_id>\d+)/(?P<label_id>\d+)/refund';
13
+
14
+ public function post( $request ) {
15
+ $response = $this->api_client->send_shipping_label_refund_request( $request[ 'label_id' ] );
16
+
17
+ if ( isset( $response->error ) ) {
18
+ $response = new WP_Error(
19
+ property_exists( $response->error, 'code' ) ? $response->error->code : 'refund_error',
20
+ property_exists( $response->error, 'message' ) ? $response->error->message : ''
21
+ );
22
+ }
23
+
24
+ if ( is_wp_error( $response ) ) {
25
+ $response->add_data( array(
26
+ 'message' => $response->get_error_message(),
27
+ ), $response->get_error_code() );
28
+
29
+ $this->logger->log( $response, __CLASS__ );
30
+ return $response;
31
+ }
32
+
33
+ $label_refund = (object) array(
34
+ 'label_id' => (int) $response->label->id,
35
+ 'refund' => $response->refund ,
36
+ );
37
+ $this->settings_store->update_label_order_meta_data( $request[ 'order_id' ], $label_refund );
38
+
39
+ return array(
40
+ 'success' => true,
41
+ 'refund' => $response->refund,
42
+ );
43
+ }
44
+
45
+ }
trunk/classes/class-wc-rest-connect-shipping-label-status-controller.php ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Shipping_Label_Status_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Shipping_Label_Status_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/label/(?P<order_id>\d+)/(?P<label_id>\d+)';
13
+
14
+ public function get( $request ) {
15
+ $response = $this->api_client->get_label_status( $request[ 'label_id' ] );
16
+
17
+ if ( is_wp_error( $response ) ) {
18
+ $error = new WP_Error(
19
+ $response->get_error_code(),
20
+ $response->get_error_message(),
21
+ array( 'message' => $response->get_error_message() )
22
+ );
23
+ $this->logger->log( $error, __CLASS__ );
24
+ return $error;
25
+ }
26
+
27
+ $label = $this->settings_store->update_label_order_meta_data( $request[ 'order_id' ], $response->label );
28
+
29
+ return array(
30
+ 'success' => true,
31
+ 'label' => $label,
32
+ );
33
+ }
34
+
35
+ }
trunk/classes/class-wc-rest-connect-shipping-rates-controller.php ADDED
@@ -0,0 +1,169 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Shipping_Rates_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Shipping_Rates_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/label/(?P<order_id>\d+)/rates';
13
+
14
+ /**
15
+ * Prefix to add in package name for making requests with multiple rates.
16
+ */
17
+ public $SPECIAL_RATE_PREFIX = '_wcs_rate_type_';
18
+
19
+ /**
20
+ * Array of extra options to collect rates for.
21
+ */
22
+ protected $extra_rates = array(
23
+ 'signature_required' => array(
24
+ 'signature' => 'yes',
25
+ ),
26
+ 'adult_signature_required' => array(
27
+ 'signature' => 'adult',
28
+ ),
29
+ );
30
+
31
+ private function has_customs_data( $package ) {
32
+ return isset( $package['contents_type'] );
33
+ }
34
+
35
+ /**
36
+ *
37
+ * @param WP_REST_Request $request - See WC_Connect_API_Client::get_label_rates()
38
+ * @return array|WP_Error
39
+ */
40
+ public function post( $request ) {
41
+ $payload = $request->get_json_params();
42
+ $payload[ 'payment_method_id' ] = $this->settings_store->get_selected_payment_method_id();
43
+ $order_id = $request[ 'order_id' ];
44
+
45
+ // This is the earliest point in the printing label flow where we are sure that
46
+ // the merchant wants to ship from this exact address (normalized or otherwise)
47
+ $this->settings_store->update_origin_address( $payload[ 'origin' ] );
48
+ $this->settings_store->update_destination_address( $order_id, $payload[ 'destination' ] );
49
+
50
+ // Update the customs information on all this order's products
51
+ $updated_product_ids = array();
52
+ foreach ( $payload[ 'packages' ] as $package_id => $package ) {
53
+ if ( ! $this->has_customs_data( $package ) ) {
54
+ break;
55
+ }
56
+ foreach ( $package[ 'items' ] as $index => $item ) {
57
+ if ( ! isset( $updated_product_ids[ $item[ 'product_id' ] ] ) ) {
58
+ $updated_product_ids[ $item[ 'product_id' ] ] = true;
59
+ update_post_meta( $item[ 'product_id' ], 'wc_connect_customs_info', array(
60
+ 'description' => $item[ 'description' ],
61
+ 'hs_tariff_number' => $item[ 'hs_tariff_number' ],
62
+ 'origin_country' => $item[ 'origin_country' ],
63
+ ) );
64
+ }
65
+ }
66
+ }
67
+
68
+ $response = $this->get_all_rates( $payload );
69
+ if ( is_wp_error( $response ) ) {
70
+ return $response;
71
+ }
72
+
73
+ return array(
74
+ 'success' => true,
75
+ 'rates' => $response,
76
+ );
77
+ }
78
+
79
+ /**
80
+ * Get standard rates along with rates for special options
81
+ * that are defined in $this->extra_rates
82
+ *
83
+ * @param stdClass $payload Request payload.
84
+ * @return WPError|stdClass
85
+ */
86
+ public function get_all_rates( $payload ) {
87
+ $signature_packages = [];
88
+ $original_package_names = [];
89
+
90
+ // Add extra package requests with special options set.
91
+ foreach( $this->extra_rates as $rate_name => $rate_option ) {
92
+ foreach( $rate_option as $option_name => $option_value ) {
93
+ foreach ( $payload['packages'] as $package_id => $package ) {
94
+ $original_package_names[] = $package['id'];
95
+ $new_package = $package;
96
+ $new_package[ $option_name ] = $option_value;
97
+
98
+ $new_package['id'] .= $this->SPECIAL_RATE_PREFIX . $rate_name;
99
+ $signature_packages[] = $new_package;
100
+ }
101
+ }
102
+ }
103
+ $payload['packages'] = array_merge( $payload['packages'], $signature_packages );
104
+
105
+ $response = $this->request_rates( $payload );
106
+ if ( is_wp_error( $response ) ) {
107
+ return $response;
108
+ }
109
+ if ( property_exists( $response, 'rates' ) ) {
110
+ return $this->merge_all_rates( $response->rates, $original_package_names );
111
+ }
112
+ return new stdClass();
113
+ }
114
+
115
+ /**
116
+ * Merge default rates together with extra rates.
117
+ *
118
+ * get_all_rates requests extra rate options as separate
119
+ * packages. This function groups these separate packages
120
+ * under the original the package name for easier parsing
121
+ * on the frontend.
122
+ *
123
+ * @param stdClass $rates Rate response for server.
124
+ * @param array $original_package_names Package names.
125
+ *
126
+ * @return array Rates
127
+ */
128
+ public function merge_all_rates( $rates, $original_package_names ) {
129
+ $parsed_rates = [];
130
+
131
+ foreach( $original_package_names as $name ) {
132
+ // Add a 'default' entry for the rate with no special options.
133
+ $parsed_rates[ $name ] = array(
134
+ 'default' => $rates->{ $name },
135
+ );
136
+
137
+ // Get package for each extra rate to group them under the original package name.
138
+ foreach( $this->extra_rates as $extra_rate_name => $option ) {
139
+ $extra_rate_package_name = $name . $this->SPECIAL_RATE_PREFIX . $extra_rate_name;
140
+ if ( isset( $rates->{ $extra_rate_package_name } ) ) {
141
+ $parsed_rates[ $name ][ $extra_rate_name ] = $rates->{ $extra_rate_package_name };
142
+ }
143
+
144
+ }
145
+ }
146
+ return $parsed_rates;
147
+ }
148
+
149
+ /**
150
+ * Make rate request.
151
+ *
152
+ * @param stdClass $payload Request payload.
153
+ * @return WPError|stdClass
154
+ */
155
+ public function request_rates( $payload ) {
156
+ $response = $this->api_client->get_label_rates( $payload );
157
+
158
+ if ( is_wp_error( $response ) ) {
159
+ $error = new WP_Error(
160
+ $response->get_error_code(),
161
+ $response->get_error_message(),
162
+ array( 'message' => $response->get_error_message() )
163
+ );
164
+ $this->logger->log( $error, __CLASS__ );
165
+ return $error;
166
+ }
167
+ return $response;
168
+ }
169
+ }
trunk/classes/class-wc-rest-connect-stripe-account-controller.php ADDED
@@ -0,0 +1,60 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Stripe_Account_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Stripe_Account_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/stripe/account';
13
+ private $stripe;
14
+
15
+ public function __construct( WC_Connect_Stripe $stripe, WC_Connect_API_Client $api_client, WC_Connect_Service_Settings_Store $settings_store, WC_Connect_Logger $logger ) {
16
+ parent::__construct( $api_client, $settings_store, $logger );
17
+ $this->stripe = $stripe;
18
+ }
19
+
20
+ public function get( $request ) {
21
+ $response = $this->stripe->get_account_details();
22
+
23
+ if ( is_wp_error( $response ) ) {
24
+ $this->logger->log( $response, __CLASS__ );
25
+
26
+ return new WP_Error(
27
+ $response->get_error_code(),
28
+ $response->get_error_message(),
29
+ array(
30
+ 'status' => 400
31
+ )
32
+ );
33
+ }
34
+
35
+ return array_merge( array( 'success' => true ), $response );
36
+ }
37
+
38
+ public function post( $request ) {
39
+ $data = $request->get_json_params();
40
+
41
+ $response = $this->stripe->create_account( $data['email'], $data['country'] );
42
+
43
+ if ( is_wp_error( $response ) ) {
44
+ $this->logger->log( $response, __CLASS__ );
45
+
46
+ return new WP_Error(
47
+ $response->get_error_code(),
48
+ $response->get_error_message(),
49
+ array(
50
+ 'status' => 400
51
+ )
52
+ );
53
+ }
54
+
55
+ return array(
56
+ 'success' => true,
57
+ 'account_id' => $response->accountId,
58
+ );
59
+ }
60
+ }
trunk/classes/class-wc-rest-connect-stripe-deauthorize-controller.php ADDED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Stripe_Deauthorize_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Stripe_Deauthorize_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/stripe/account/deauthorize';
13
+ private $stripe;
14
+
15
+ public function __construct( WC_Connect_Stripe $stripe, WC_Connect_API_Client $api_client, WC_Connect_Service_Settings_Store $settings_store, WC_Connect_Logger $logger ) {
16
+ parent::__construct( $api_client, $settings_store, $logger );
17
+ $this->stripe = $stripe;
18
+ }
19
+
20
+ public function post( $request ) {
21
+ $response = $this->stripe->deauthorize_account();
22
+
23
+ if ( is_wp_error( $response ) ) {
24
+ $this->logger->log( $response, __CLASS__ );
25
+
26
+ return new WP_Error(
27
+ $response->get_error_code(),
28
+ $response->get_error_message(),
29
+ array(
30
+ 'status' => 400
31
+ )
32
+ );
33
+ }
34
+
35
+ return array(
36
+ 'success' => true,
37
+ 'account_id' => $response->accountId,
38
+ );
39
+ }
40
+ }
trunk/classes/class-wc-rest-connect-stripe-oauth-connect-controller.php ADDED
@@ -0,0 +1,42 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Stripe_Oauth_Connect_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Stripe_Oauth_Connect_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/stripe/oauth/connect';
13
+ private $stripe;
14
+
15
+ public function __construct( WC_Connect_Stripe $stripe, WC_Connect_API_Client $api_client, WC_Connect_Service_Settings_Store $settings_store, WC_Connect_Logger $logger ) {
16
+ parent::__construct( $api_client, $settings_store, $logger );
17
+ $this->stripe = $stripe;
18
+ }
19
+
20
+ public function post( $request ) {
21
+ $data = $request->get_json_params();
22
+
23
+ $response = $this->stripe->connect_oauth( $data['state'], $data['code'] );
24
+
25
+ if ( is_wp_error( $response ) ) {
26
+ $this->logger->log( $response, __CLASS__ );
27
+
28
+ return new WP_Error(
29
+ $response->get_error_code(),
30
+ $response->get_error_message(),
31
+ array(
32
+ 'status' => 400
33
+ )
34
+ );
35
+ }
36
+
37
+ return array(
38
+ 'success' => true,
39
+ 'account_id' => $response->accountId,
40
+ );
41
+ }
42
+ }
trunk/classes/class-wc-rest-connect-stripe-oauth-init-controller.php ADDED
@@ -0,0 +1,41 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Stripe_Oauth_Init_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Stripe_Oauth_Init_Controller extends WC_REST_Connect_Base_Controller {
12
+ protected $rest_base = 'connect/stripe/oauth/init';
13
+ private $stripe;
14
+
15
+ public function __construct( WC_Connect_Stripe $stripe, WC_Connect_API_Client $api_client, WC_Connect_Service_Settings_Store $settings_store, WC_Connect_Logger $logger ) {
16
+ parent::__construct( $api_client, $settings_store, $logger );
17
+ $this->stripe = $stripe;
18
+ }
19
+
20
+ public function post( $request ) {
21
+ $data = $request->get_json_params();
22
+ $response = $this->stripe->get_oauth_url( isset( $data['returnUrl'] ) ? $data['returnUrl'] : '' );
23
+
24
+ if ( is_wp_error( $response ) ) {
25
+ $this->logger->log( $response, __CLASS__ );
26
+
27
+ return new WP_Error(
28
+ $response->get_error_code(),
29
+ $response->get_error_message(),
30
+ array(
31
+ 'status' => 400
32
+ )
33
+ );
34
+ }
35
+
36
+ return array(
37
+ 'success' => true,
38
+ 'oauthUrl' => $response,
39
+ );
40
+ }
41
+ }
trunk/classes/class-wc-rest-connect-tos-controller.php ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
+ }
6
+
7
+ if ( class_exists( 'WC_REST_Connect_Tos_Controller' ) ) {
8
+ return;
9
+ }
10
+
11
+ class WC_REST_Connect_Tos_Controller extends WC_REST_Connect_Base_Controller {
12
+
13
+ protected $rest_base = 'connect/tos';
14
+
15
+ public function get() {
16
+ return new WP_REST_Response( array(
17
+ 'success' => true,
18
+ 'accepted' => WC_Connect_Options::get_option( 'tos_accepted' ),
19
+ ), 200 );
20
+ }
21
+
22
+ public function post( $request ) {
23
+ $settings = $request->get_json_params();
24
+
25
+ if ( ! $settings || ! isset( $settings[ 'accepted' ] ) || ! $settings[ 'accepted' ] ) {
26
+ return new WP_Error( 'bad_request', __( 'Bad request', 'woocommerce-services' ), array( 'status' => 400 ) );
27
+ }
28
+
29
+ WC_Connect_Options::update_option( 'tos_accepted', true );
30
+
31
+ return new WP_REST_Response( array(
32
+ 'success' => true,
33
+ 'accepted' => WC_Connect_Options::get_option( 'tos_accepted' ),
34
+ ), 200 );
35
+ }
36
+
37
+ /**
38
+ * Validate the requester's permissions
39
+ */
40
+ public function check_permission( $request ) {
41
+ return current_user_can( 'manage_woocommerce' ) &&
42
+ current_user_can( 'install_plugins' ) &&
43
+ current_user_can( 'activate_plugins' );
44
+ }
45
+ }
trunk/classes/wc-api-dev/class-wc-rest-dev-data-continents-controller.php ADDED
@@ -0,0 +1,357 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * REST API Data controller.
4
+ *
5
+ * Handles requests to the /data/continents endpoint.
6
+ *
7
+ * Directly copied from the wc-api-dev plugin. Delete this when the "v3" REST API is included in all the WC versions we support.
8
+ *
9
+ * @author Automattic
10
+ * @category API
11
+ * @package WooCommerce/API
12
+ * @since 3.1.0
13
+ */
14
+
15
+ if ( ! defined( 'ABSPATH' ) ) {
16
+ exit;
17
+ }
18
+
19
+ /**
20
+ * REST API Data controller class.
21
+ *
22
+ * @package WooCommerce/API
23
+ * @extends WC_REST_Controller
24
+ */
25
+ class WC_REST_Dev_Data_Continents_Controller extends WC_REST_Dev_Data_Controller {
26
+
27
+ /**
28
+ * Endpoint namespace.
29
+ *
30
+ * @var string
31
+ */
32
+ protected $namespace = 'wc/v3';
33
+
34
+ /**
35
+ * Route base.
36
+ *
37
+ * @var string
38
+ */
39
+ protected $rest_base = 'data/continents';
40
+
41
+ /**
42
+ * Register routes.
43
+ *
44
+ * @since 3.1.0
45
+ */
46
+ public function register_routes() {
47
+ register_rest_route( $this->namespace, '/' . $this->rest_base, array(
48
+ array(
49
+ 'methods' => WP_REST_Server::READABLE,
50
+ 'callback' => array( $this, 'get_items' ),
51
+ 'permission_callback' => array( $this, 'get_items_permissions_check' ),
52
+ ),
53
+ 'schema' => array( $this, 'get_public_item_schema' ),
54
+ ) );
55
+ register_rest_route( $this->namespace, '/' . $this->rest_base . '/(?P<location>[\w-]+)', array(
56
+ array(
57
+ 'methods' => WP_REST_Server::READABLE,
58
+ 'callback' => array( $this, 'get_item' ),
59
+ 'permission_callback' => array( $this, 'get_items_permissions_check' ),
60
+ 'args' => array(
61
+ 'continent' => array(
62
+ 'description' => __( '2 character continent code.', 'woocommerce' ),
63
+ 'type' => 'string',
64
+ ),
65
+ ),
66
+ ),
67
+ 'schema' => array( $this, 'get_public_item_schema' ),
68
+ ) );
69
+ }
70
+
71
+ /**
72
+ * Return the list of countries and states for a given continent.
73
+ *
74
+ * @since 3.1.0
75
+ * @param string $continent_code
76
+ * @param WP_REST_Request $request
77
+ * @return array|mixed Response data, ready for insertion into collection data.
78
+ */
79
+ public function get_continent( $continent_code = false, $request ) {
80
+ $continents = WC()->countries->get_continents();
81
+ $countries = WC()->countries->get_countries();
82
+ $states = WC()->countries->get_states();
83
+ $locale_info = include WC()->plugin_path() . '/i18n/locale-info.php';
84
+ $data = array();
85
+
86
+ if ( ! array_key_exists( $continent_code, $continents ) ) {
87
+ return false;
88
+ }
89
+
90
+ $continent_list = $continents[ $continent_code ];
91
+
92
+ $continent = array(
93
+ 'code' => $continent_code,
94
+ 'name' => $continent_list['name'],
95
+ );
96
+
97
+ $local_countries = array();
98
+ foreach ( $continent_list['countries'] as $country_code ) {
99
+ if ( isset( $countries[ $country_code ] ) ) {
100
+ $country = array(
101
+ 'code' => $country_code,
102
+ 'name' => $countries[ $country_code ],
103
+ );
104
+
105
+ // If we have detailed locale information include that in the response
106
+ if ( array_key_exists( $country_code, $locale_info ) ) {
107
+ // Defensive programming against unexpected changes in locale-info.php
108
+ $country_data = wp_parse_args( $locale_info[ $country_code ], array(
109
+ 'currency_code' => 'USD',
110
+ 'currency_pos' => 'left',
111
+ 'decimal_sep' => '.',
112
+ 'dimension_unit' => 'in',
113
+ 'num_decimals' => 2,
114
+ 'thousand_sep' => ',',
115
+ 'weight_unit' => 'lbs',
116
+ ) );
117
+
118
+ $country = array_merge( $country, $country_data );
119
+ }
120
+
121
+ $local_states = array();
122
+ if ( isset( $states[ $country_code ] ) ) {
123
+ foreach ( $states[ $country_code ] as $state_code => $state_name ) {
124
+ $local_states[] = array(
125
+ 'code' => $state_code,
126
+ 'name' => $state_name,
127
+ );
128
+ }
129
+ }
130
+ $country['states'] = $local_states;
131
+
132
+ // Allow only desired keys (e.g. filter out tax rates)
133
+ $allowed = array(
134
+ 'code',
135
+ 'currency_code',
136
+ 'currency_pos',
137
+ 'decimal_sep',
138
+ 'dimension_unit',
139
+ 'name',
140
+ 'num_decimals',
141
+ 'states',
142
+ 'thousand_sep',
143
+ 'weight_unit',
144
+ );
145
+ $country = array_intersect_key( $country, array_flip( $allowed ) );
146
+
147
+ $local_countries[] = $country;
148
+ }
149
+ }
150
+
151
+ $continent['countries'] = $local_countries;
152
+ return $continent;
153
+ }
154
+
155
+ /**
156
+ * Return the list of states for all continents.
157
+ *
158
+ * @since 3.1.0
159
+ * @param WP_REST_Request $request
160
+ * @return WP_Error|WP_REST_Response
161
+ */
162
+ public function get_items( $request ) {
163
+ $continents = WC()->countries->get_continents();
164
+ $data = array();
165
+
166
+ foreach ( array_keys( $continents ) as $continent_code ) {
167
+ $continent = $this->get_continent( $continent_code, $request );
168
+ $response = $this->prepare_item_for_response( $continent, $request );
169
+ $data[] = $this->prepare_response_for_collection( $response );
170
+ }
171
+
172
+ return rest_ensure_response( $data );
173
+ }
174
+
175
+ /**
176
+ * Return the list of locations for a given continent.
177
+ *
178
+ * @since 3.1.0
179
+ * @param WP_REST_Request $request
180
+ * @return WP_Error|WP_REST_Response
181
+ */
182
+ public function get_item( $request ) {
183
+ $data = $this->get_continent( strtoupper( $request['location'] ), $request );
184
+ if ( empty( $data ) ) {
185
+ return new WP_Error( 'woocommerce_rest_data_invalid_location', __( 'There are no locations matching these parameters.', 'woocommerce' ), array( 'status' => 404 ) );
186
+ }
187
+ return $this->prepare_item_for_response( $data, $request );
188
+ }
189
+
190
+ /**
191
+ * Prepare the data object for response.
192
+ *
193
+ * @since 3.1.0
194
+ * @param object $item Data object.
195
+ * @param WP_REST_Request $request Request object.
196
+ * @return WP_REST_Response $response Response data.
197
+ */
198
+ public function prepare_item_for_response( $item, $request ) {
199
+ $data = $this->add_additional_fields_to_object( $item, $request );
200
+ $data = $this->filter_response_by_context( $data, 'view' );
201
+ $response = rest_ensure_response( $data );
202
+
203
+ $response->add_links( $this->prepare_links( $item ) );
204
+
205
+ /**
206
+ * Filter the location list returned from the API.
207
+ *
208
+ * Allows modification of the loction data right before it is returned.
209
+ *
210
+ * @param WP_REST_Response $response The response object.
211
+ * @param array $item The original list of continent(s), countries, and states.
212
+ * @param WP_REST_Request $request Request used to generate the response.
213
+ */
214
+ return apply_filters( 'woocommerce_rest_prepare_data_continent', $response, $item, $request );
215
+ }
216
+
217
+ /**
218
+ * Prepare links for the request.
219
+ *
220
+ * @param object $item Data object.
221
+ * @return array Links for the given continent.
222
+ */
223
+ protected function prepare_links( $item ) {
224
+ $continent_code = strtolower( $item['code'] );
225
+ $links = array(
226
+ 'self' => array(
227
+ 'href' => rest_url( sprintf( '/%s/%s/%s', $this->namespace, $this->rest_base, $continent_code ) ),
228
+ ),
229
+ 'collection' => array(
230
+ 'href' => rest_url( sprintf( '/%s/%s', $this->namespace, $this->rest_base ) ),
231
+ ),
232
+ );
233
+ return $links;
234
+ }
235
+
236
+ /**
237
+ * Get the location schema, conforming to JSON Schema.
238
+ *
239
+ * @since 3.1.0
240
+ * @return array
241
+ */
242
+ public function get_item_schema() {
243
+ $schema = array(
244
+ '$schema' => 'http://json-schema.org/draft-04/schema#',
245
+ 'title' => 'data_continents',
246
+ 'type' => 'object',
247
+ 'properties' => array(
248
+ 'code' => array(
249
+ 'type' => 'string',
250
+ 'description' => __( '2 character continent code.', 'woocommerce' ),
251
+ 'context' => array( 'view' ),
252
+ 'readonly' => true,
253
+ ),
254
+ 'name' => array(
255
+ 'type' => 'string',
256
+ 'description' => __( 'Full name of continent.', 'woocommerce' ),
257
+ 'context' => array( 'view' ),
258
+ 'readonly' => true,
259
+ ),
260
+ 'countries' => array(
261
+ 'type' => 'array',
262
+ 'description' => __( 'List of countries on this continent.', 'woocommerce' ),
263
+ 'context' => array( 'view' ),
264
+ 'readonly' => true,
265
+ 'items' => array(
266
+ 'type' => 'object',
267
+ 'context' => array( 'view' ),
268
+ 'readonly' => true,
269
+ 'properties' => array(
270
+ 'code' => array(
271
+ 'type' => 'string',
272
+ 'description' => __( 'ISO3166 alpha-2 country code.', 'woocommerce' ),
273
+ 'context' => array( 'view' ),
274
+ 'readonly' => true,
275
+ ),
276
+ 'currency_code' => array(
277
+ 'type' => 'string',
278
+ 'description' => __( 'Default ISO4127 alpha-3 currency code for the country.', 'woocommerce' ),
279
+ 'context' => array( 'view' ),
280
+ 'readonly' => true,
281
+ ),
282
+ 'currency_pos' => array(
283
+ 'type' => 'string',
284
+ 'description' => __( 'Currency symbol position for this country.', 'woocommerce' ),
285
+ 'context' => array( 'view' ),
286
+ 'readonly' => true,
287
+ ),
288
+ 'decimal_sep' => array(
289
+ 'type' => 'string',
290
+ 'description' => __( 'Decimal separator for displayed prices for this country.', 'woocommerce' ),
291
+ 'context' => array( 'view' ),
292
+ 'readonly' => true,
293
+ ),
294
+ 'dimension_unit' => array(
295
+ 'type' => 'string',
296
+ 'description' => __( 'The unit lengths are defined in for this country.', 'woocommerce' ),
297
+ 'context' => array( 'view' ),
298
+ 'readonly' => true,
299
+ ),
300
+ 'name' => array(
301
+ 'type' => 'string',
302
+ 'description' => __( 'Full name of country.', 'woocommerce' ),
303
+ 'context' => array( 'view' ),
304
+ 'readonly' => true,
305
+ ),
306
+ 'num_decimals' => array(
307
+ 'type' => 'integer',
308
+ 'description' => __( 'Number of decimal points shown in displayed prices for this country.', 'woocommerce' ),
309
+ 'context' => array( 'view' ),
310
+ 'readonly' => true,
311
+ ),
312
+ 'states' => array(
313
+ 'type' => 'array',
314
+ 'description' => __( 'List of states in this country.', 'woocommerce' ),
315
+ 'context' => array( 'view' ),
316
+ 'readonly' => true,
317
+ 'items' => array(
318
+ 'type' => 'object',
319
+ 'context' => array( 'view' ),
320
+ 'readonly' => true,
321
+ 'properties' => array(
322
+ 'code' => array(
323
+ 'type' => 'string',
324
+ 'description' => __( 'State code.', 'woocommerce' ),
325
+ 'context' => array( 'view' ),
326
+ 'readonly' => true,
327
+ ),
328
+ 'name' => array(
329
+ 'type' => 'string',
330
+ 'description' => __( 'Full name of state.', 'woocommerce' ),
331
+ 'context' => array( 'view' ),
332
+ 'readonly' => true,
333
+ ),
334
+ ),
335
+ ),
336
+ ),
337
+ 'thousand_sep' => array(
338
+ 'type' => 'string',
339
+ 'description' => __( 'Thousands separator for displayed prices in this country.', 'woocommerce' ),
340
+ 'context' => array( 'view' ),
341
+ 'readonly' => true,
342
+ ),
343
+ 'weight_unit' => array(
344
+ 'type' => 'string',
345
+ 'description' => __( 'The unit weights are defined in for this country.', 'woocommerce' ),
346
+ 'context' => array( 'view' ),
347
+ 'readonly' => true,
348
+ ),
349
+ ),
350
+ ),
351
+ ),
352
+ ),
353
+ );
354
+
355
+ return $this->add_additional_fields_schema( $schema );
356
+ }
357
+ }
trunk/classes/wc-api-dev/class-wc-rest-dev-data-controller.php ADDED
@@ -0,0 +1,188 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * REST API Data controller.
4
+ *
5
+ * Handles requests to the /data endpoint.
6
+ *
7
+ * Directly copied from the wc-api-dev plugin. Delete this when the "v3" REST API is included in all the WC versions we support.
8
+ *
9
+ * @author Automattic
10
+ * @category API
11
+ * @package WooCommerce/API
12
+ * @since 3.1.0
13
+ */
14
+
15
+ if ( ! defined( 'ABSPATH' ) ) {
16
+ exit;
17
+ }
18
+
19
+ /**
20
+ * REST API Data controller class.
21
+ *
22
+ * @package WooCommerce/API
23
+ * @extends WC_REST_Controller
24
+ */
25
+ class WC_REST_Dev_Data_Controller extends WC_REST_Controller {
26
+
27
+ /**
28
+ * Endpoint namespace.
29
+ *
30
+ * @var string
31
+ */
32
+ protected $namespace = 'wc/v3';
33
+
34
+ /**
35
+ * Route base.
36
+ *
37
+ * @var string
38
+ */
39
+ protected $rest_base = 'data';
40
+
41
+ /**
42
+ * Register routes.
43
+ *
44
+ * @since 3.1.0
45
+ */
46
+ public function register_routes() {
47
+ register_rest_route( $this->namespace, '/' . $this->rest_base, array(
48
+ array(
49
+ 'methods' => WP_REST_Server::READABLE,
50
+ 'callback' => array( $this, 'get_items' ),
51
+ 'permission_callback' => array( $this, 'get_items_permissions_check' ),
52
+ ),
53
+ 'schema' => array( $this, 'get_public_item_schema' ),
54
+ ) );
55
+ }
56
+
57
+ /**
58
+ * Check whether a given request has permission to read site data.
59
+ *
60
+ * @param WP_REST_Request $request Full details about the request.
61
+ * @return WP_Error|boolean
62
+ */
63
+ public function get_items_permissions_check( $request ) {
64
+ if ( ! wc_rest_check_manager_permissions( 'settings', 'read' ) ) {
65
+ return new WP_Error( 'woocommerce_rest_cannot_view', __( 'Sorry, you cannot list resources.', 'woocommerce' ), array( 'status' => rest_authorization_required_code() ) );
66
+ }
67
+
68
+ return true;
69
+ }
70
+
71
+ /**
72
+ * Check whether a given request has permission to read site settings.
73
+ *
74
+ * @param WP_REST_Request $request Full details about the request.
75
+ * @return WP_Error|boolean
76
+ */
77
+ public function get_item_permissions_check( $request ) {
78
+ if ( ! wc_rest_check_manager_permissions( 'settings', 'read' ) ) {
79
+ return new WP_Error( 'woocommerce_rest_cannot_view', __( 'Sorry, you cannot view this resource.', 'woocommerce' ), array( 'status' => rest_authorization_required_code() ) );
80
+ }
81
+
82
+ return true;
83
+ }
84
+
85
+ /**
86
+ * Return the list of data resources.
87
+ *
88
+ * @since 3.1.0
89
+ * @param WP_REST_Request $request
90
+ * @return WP_Error|WP_REST_Response
91
+ */
92
+ public function get_items( $request ) {
93
+ $data = array();
94
+ $resources = array(
95
+ array(
96
+ 'slug' => 'continents',
97
+ 'description' => __( 'List of supported continents, countries, and states.', 'woocommerce' ),
98
+ ),
99
+ array(
100
+ 'slug' => 'countries',
101
+ 'description' => __( 'List of supported states in a given country.', 'woocommerce' ),
102
+ ),
103
+ array(
104
+ 'slug' => 'currencies',
105
+ 'description' => __( 'List of supported currencies.', 'woocommerce' ),
106
+ ),
107
+ );
108
+
109
+ foreach ( $resources as $resource ) {
110
+ $item = $this->prepare_item_for_response( (object) $resource, $request );
111
+ $data[] = $this->prepare_response_for_collection( $item );
112
+ }
113
+
114
+ return rest_ensure_response( $data );
115
+ }
116
+
117
+ /**
118
+ * Prepare a data resource object for serialization.
119
+ *
120
+ * @param stdClass $report Report data.
121
+ * @param WP_REST_Request $request Request object.
122
+ * @return WP_REST_Response $response Response data.
123
+ */
124
+ public function prepare_item_for_response( $resource, $request ) {
125
+ $data = array(
126
+ 'slug' => $resource->slug,
127
+ 'description' => $resource->description,
128
+ );
129
+
130
+ $data = $this->add_additional_fields_to_object( $data, $request );
131
+ $data = $this->filter_response_by_context( $data, 'view' );
132
+
133
+ // Wrap the data in a response object.
134
+ $response = rest_ensure_response( $data );
135
+ $response->add_links( $this->prepare_links( $resource ) );
136
+
137
+ return $response;
138
+ }
139
+
140
+ /**
141
+ * Prepare links for the request.
142
+ *
143
+ * @param object $item Data object.
144
+ * @return array Links for the given country.
145
+ */
146
+ protected function prepare_links( $item ) {
147
+ $links = array(
148
+ 'self' => array(
149
+ 'href' => rest_url( sprintf( '/%s/%s/%s', $this->namespace, $this->rest_base, $item->slug ) ),
150
+ ),
151
+ 'collection' => array(
152
+ 'href' => rest_url( sprintf( '%s/%s', $this->namespace, $this->rest_base ) ),
153
+ ),
154
+ );
155
+
156
+ return $links;
157
+ }
158
+
159
+ /**
160
+ * Get the data index schema, conforming to JSON Schema.
161
+ *
162
+ * @since 3.1.0
163
+ * @return array
164
+ */
165
+ public function get_item_schema() {
166
+ $schema = array(
167
+ '$schema' => 'http://json-schema.org/draft-04/schema#',
168
+ 'title' => 'data_index',
169
+ 'type' => 'object',
170
+ 'properties' => array(
171
+ 'slug' => array(
172
+ 'description' => __( 'Data resource ID.', 'woocommerce' ),
173
+ 'type' => 'string',
174
+ 'context' => array( 'view' ),
175
+ 'readonly' => true,
176
+ ),
177
+ 'description' => array(
178
+ 'description' => __( 'Data resource description.', 'woocommerce' ),
179
+ 'type' => 'string',
180
+ 'context' => array( 'view' ),
181
+ 'readonly' => true,
182
+ ),
183
+ ),
184
+ );
185
+
186
+ return $this->add_additional_fields_schema( $schema );
187
+ }
188
+ }
trunk/dist/woocommerce-services-1.22.4.css ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .wp-core-ui.wp-admin .wcc-root form ul{margin:0;padding:0;list-style:none}.wp-core-ui.wp-admin .wcc-root input[type='text'],.wp-core-ui.wp-admin .wcc-root input[type='search'],.wp-core-ui.wp-admin .wcc-root input[type='email'],.wp-core-ui.wp-admin .wcc-root input[type='number'],.wp-core-ui.wp-admin .wcc-root input[type='password'],.wp-core-ui.wp-admin .wcc-root input[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input[type='radio'],.wp-core-ui.wp-admin .wcc-root input[type='tel'],.wp-core-ui.wp-admin .wcc-root input[type='url'],.wp-core-ui.wp-admin .wcc-root textarea{margin:0;padding:7px 14px;width:100%;color:#3d4145;font-size:16px;line-height:1.5;border:1px solid #ccced0;background-color:#fff;transition:all 0.15s ease-in-out;box-sizing:border-box}.wp-core-ui.wp-admin .wcc-root input[type='text']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='search']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='email']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='number']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='password']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='checkbox']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='radio']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='tel']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='url']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root textarea:-ms-input-placeholder{color:#636d75}.wp-core-ui.wp-admin .wcc-root input[type='text']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='search']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='email']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='number']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='password']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='checkbox']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='radio']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='tel']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='url']::placeholder,.wp-core-ui.wp-admin .wcc-root textarea::placeholder{color:#636d75}.wp-core-ui.wp-admin .wcc-root input:hover[type='text'],.wp-core-ui.wp-admin .wcc-root input:hover[type='search'],.wp-core-ui.wp-admin .wcc-root input:hover[type='email'],.wp-core-ui.wp-admin .wcc-root input:hover[type='number'],.wp-core-ui.wp-admin .wcc-root input:hover[type='password'],.wp-core-ui.wp-admin .wcc-root input:hover[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input:hover[type='radio'],.wp-core-ui.wp-admin .wcc-root input:hover[type='tel'],.wp-core-ui.wp-admin .wcc-root input:hover[type='url'],.wp-core-ui.wp-admin .wcc-root textarea:hover{border-color:#b0b5b8}.wp-core-ui.wp-admin .wcc-root input:focus[type='text'],.wp-core-ui.wp-admin .wcc-root input:focus[type='search'],.wp-core-ui.wp-admin .wcc-root input:focus[type='email'],.wp-core-ui.wp-admin .wcc-root input:focus[type='number'],.wp-core-ui.wp-admin .wcc-root input:focus[type='password'],.wp-core-ui.wp-admin .wcc-root input:focus[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input:focus[type='radio'],.wp-core-ui.wp-admin .wcc-root input:focus[type='tel'],.wp-core-ui.wp-admin .wcc-root input:focus[type='url'],.wp-core-ui.wp-admin .wcc-root textarea:focus{border-color:#016087;outline:none;box-shadow:0 0 0 2px #bbc9d5}.wp-core-ui.wp-admin .wcc-root input:focus:hover[type='text'],.wp-core-ui.wp-admin .wcc-root input:focus:hover[type='search'],.wp-core-ui.wp-admin .wcc-root input:focus:hover[type='email'],.wp-core-ui.wp-admin .wcc-root input:focus:hover[type='number'],.wp-core-ui.wp-admin .wcc-root input:focus:hover[type='password'],.wp-core-ui.wp-admin .wcc-root input:focus:hover[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input:focus:hover[type='radio'],.wp-core-ui.wp-admin .wcc-root input:focus:hover[type='tel'],.wp-core-ui.wp-admin .wcc-root input:focus:hover[type='url'],.wp-core-ui.wp-admin .wcc-root textarea:focus:hover{box-shadow:0 0 0 2px #95adc1}.wp-core-ui.wp-admin .wcc-root input[type='text']:focus::-ms-clear,.wp-core-ui.wp-admin .wcc-root input[type='search']:focus::-ms-clear,.wp-core-ui.wp-admin .wcc-root input[type='email']:focus::-ms-clear,.wp-core-ui.wp-admin .wcc-root input[type='number']:focus::-ms-clear,.wp-core-ui.wp-admin .wcc-root input[type='password']:focus::-ms-clear,.wp-core-ui.wp-admin .wcc-root input[type='checkbox']:focus::-ms-clear,.wp-core-ui.wp-admin .wcc-root input[type='radio']:focus::-ms-clear,.wp-core-ui.wp-admin .wcc-root input[type='tel']:focus::-ms-clear,.wp-core-ui.wp-admin .wcc-root input[type='url']:focus::-ms-clear,.wp-core-ui.wp-admin .wcc-root textarea:focus::-ms-clear{display:none}.wp-core-ui.wp-admin .wcc-root input:disabled[type='text'],.wp-core-ui.wp-admin .wcc-root input:disabled[type='search'],.wp-core-ui.wp-admin .wcc-root input:disabled[type='email'],.wp-core-ui.wp-admin .wcc-root input:disabled[type='number'],.wp-core-ui.wp-admin .wcc-root input:disabled[type='password'],.wp-core-ui.wp-admin .wcc-root input:disabled[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input:disabled[type='radio'],.wp-core-ui.wp-admin .wcc-root input:disabled[type='tel'],.wp-core-ui.wp-admin .wcc-root input:disabled[type='url'],.wp-core-ui.wp-admin .wcc-root textarea:disabled{background:#f6f6f6;border-color:#f6f6f6;color:#b0b5b8;opacity:1;-webkit-text-fill-color:#b0b5b8}.wp-core-ui.wp-admin .wcc-root input:disabled:hover[type='text'],.wp-core-ui.wp-admin .wcc-root input:disabled:hover[type='search'],.wp-core-ui.wp-admin .wcc-root input:disabled:hover[type='email'],.wp-core-ui.wp-admin .wcc-root input:disabled:hover[type='number'],.wp-core-ui.wp-admin .wcc-root input:disabled:hover[type='password'],.wp-core-ui.wp-admin .wcc-root input:disabled:hover[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input:disabled:hover[type='radio'],.wp-core-ui.wp-admin .wcc-root input:disabled:hover[type='tel'],.wp-core-ui.wp-admin .wcc-root input:disabled:hover[type='url'],.wp-core-ui.wp-admin .wcc-root textarea:disabled:hover{cursor:default}.wp-core-ui.wp-admin .wcc-root input[type='text']:disabled:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='search']:disabled:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='email']:disabled:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='number']:disabled:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='password']:disabled:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='checkbox']:disabled:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='radio']:disabled:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='tel']:disabled:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='url']:disabled:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root textarea:disabled:-ms-input-placeholder{color:#b0b5b8}.wp-core-ui.wp-admin .wcc-root input[type='text']:disabled::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='search']:disabled::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='email']:disabled::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='number']:disabled::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='password']:disabled::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='checkbox']:disabled::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='radio']:disabled::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='tel']:disabled::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='url']:disabled::placeholder,.wp-core-ui.wp-admin .wcc-root textarea:disabled::placeholder{color:#b0b5b8}.wp-core-ui.wp-admin .wcc-root input.is-valid[type='text'],.wp-core-ui.wp-admin .wcc-root input.is-valid[type='search'],.wp-core-ui.wp-admin .wcc-root input.is-valid[type='email'],.wp-core-ui.wp-admin .wcc-root input.is-valid[type='number'],.wp-core-ui.wp-admin .wcc-root input.is-valid[type='password'],.wp-core-ui.wp-admin .wcc-root input.is-valid[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input.is-valid[type='radio'],.wp-core-ui.wp-admin .wcc-root input.is-valid[type='tel'],.wp-core-ui.wp-admin .wcc-root input.is-valid[type='url'],.wp-core-ui.wp-admin .wcc-root textarea.is-valid{border-color:#008a00}.wp-core-ui.wp-admin .wcc-root input.is-valid:hover[type='text'],.wp-core-ui.wp-admin .wcc-root input.is-valid:hover[type='search'],.wp-core-ui.wp-admin .wcc-root input.is-valid:hover[type='email'],.wp-core-ui.wp-admin .wcc-root input.is-valid:hover[type='number'],.wp-core-ui.wp-admin .wcc-root input.is-valid:hover[type='password'],.wp-core-ui.wp-admin .wcc-root input.is-valid:hover[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input.is-valid:hover[type='radio'],.wp-core-ui.wp-admin .wcc-root input.is-valid:hover[type='tel'],.wp-core-ui.wp-admin .wcc-root input.is-valid:hover[type='url'],.wp-core-ui.wp-admin .wcc-root textarea.is-valid:hover{border-color:#0d5a10}.wp-core-ui.wp-admin .wcc-root input.is-error[type='text'],.wp-core-ui.wp-admin .wcc-root input.is-error[type='search'],.wp-core-ui.wp-admin .wcc-root input.is-error[type='email'],.wp-core-ui.wp-admin .wcc-root input.is-error[type='number'],.wp-core-ui.wp-admin .wcc-root input.is-error[type='password'],.wp-core-ui.wp-admin .wcc-root input.is-error[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input.is-error[type='radio'],.wp-core-ui.wp-admin .wcc-root input.is-error[type='tel'],.wp-core-ui.wp-admin .wcc-root input.is-error[type='url'],.wp-core-ui.wp-admin .wcc-root textarea.is-error{border-color:#eb0001}.wp-core-ui.wp-admin .wcc-root input.is-error:hover[type='text'],.wp-core-ui.wp-admin .wcc-root input.is-error:hover[type='search'],.wp-core-ui.wp-admin .wcc-root input.is-error:hover[type='email'],.wp-core-ui.wp-admin .wcc-root input.is-error:hover[type='number'],.wp-core-ui.wp-admin .wcc-root input.is-error:hover[type='password'],.wp-core-ui.wp-admin .wcc-root input.is-error:hover[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input.is-error:hover[type='radio'],.wp-core-ui.wp-admin .wcc-root input.is-error:hover[type='tel'],.wp-core-ui.wp-admin .wcc-root input.is-error:hover[type='url'],.wp-core-ui.wp-admin .wcc-root textarea.is-error:hover{border-color:#ac120b}.wp-core-ui.wp-admin .wcc-root input:focus.is-valid[type='text'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid[type='search'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid[type='email'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid[type='number'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid[type='password'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid[type='radio'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid[type='tel'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid[type='url'],.wp-core-ui.wp-admin .wcc-root textarea:focus.is-valid{box-shadow:0 0 0 2px #c5e6b9}.wp-core-ui.wp-admin .wcc-root input:focus.is-valid:hover[type='text'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid:hover[type='search'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid:hover[type='email'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid:hover[type='number'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid:hover[type='password'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid:hover[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid:hover[type='radio'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid:hover[type='tel'],.wp-core-ui.wp-admin .wcc-root input:focus.is-valid:hover[type='url'],.wp-core-ui.wp-admin .wcc-root textarea:focus.is-valid:hover{box-shadow:0 0 0 2px #9dcf8d}.wp-core-ui.wp-admin .wcc-root input:focus.is-error[type='text'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error[type='search'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error[type='email'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error[type='number'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error[type='password'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error[type='radio'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error[type='tel'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error[type='url'],.wp-core-ui.wp-admin .wcc-root textarea:focus.is-error{box-shadow:0 0 0 2px #ffcfac}.wp-core-ui.wp-admin .wcc-root input:focus.is-error:hover[type='text'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error:hover[type='search'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error:hover[type='email'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error:hover[type='number'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error:hover[type='password'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error:hover[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error:hover[type='radio'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error:hover[type='tel'],.wp-core-ui.wp-admin .wcc-root input:focus.is-error:hover[type='url'],.wp-core-ui.wp-admin .wcc-root textarea:focus.is-error:hover{box-shadow:0 0 0 2px #ffab78}.wp-core-ui.wp-admin .wcc-root textarea{min-height:92px}.color-scheme.is-classic-blue{--color-accent: #d7730f;--color-accent-rgb: 215,115,15;--color-accent-dark: #994b1f;--color-accent-dark-rgb: 153,75,31;--color-accent-light: #eda268;--color-accent-light-rgb: 237,162,104;--color-accent-0: #fef7f2;--color-accent-0-rgb: 254,247,242;--color-accent-50: #fce4d5;--color-accent-50-rgb: 252,228,213;--color-accent-100: #fad2b6;--color-accent-100-rgb: 250,210,182;--color-accent-200: #f5ba8f;--color-accent-200-rgb: 245,186,143;--color-accent-300: #eda268;--color-accent-300-rgb: 237,162,104;--color-accent-400: #e38a40;--color-accent-400-rgb: 227,138,64;--color-accent-500: #d7730f;--color-accent-500-rgb: 215,115,15;--color-accent-600: #b95e1b;--color-accent-600-rgb: 185,94,27;--color-accent-700: #994b1f;--color-accent-700-rgb: 153,75,31;--color-accent-800: #79391f;--color-accent-800-rgb: 121,57,31;--color-accent-900: #592a1b;--color-accent-900-rgb: 89,42,27;--color-button-primary-background-hover: #e38a40;--sidebar-background: #e1e2e2;--sidebar-background-gradient: 225,226,226;--sidebar-heading-color: #50575d;--sidebar-border-color: #ccced0;--sidebar-menu-a-first-child-after-background: 225,226,226;--sidebar-menu-selected-background-color: #636d75;--sidebar-menu-selected-a-color: #fff;--sidebar-menu-selected-a-first-child-after-background: 99,109,117;--sidebar-menu-hover-background: #fff;--sidebar-menu-hover-background-gradient: 255,255,255;--sidebar-menu-hover-color: #016087;--profile-gravatar-user-secondary-info-color: #636d75}.color-scheme.is-powder-snow{--color-primary: #1a1a1a;--color-primary-rgb: 26,26,26;--color-primary-light: #969ca1;--color-primary-light-rgb: 150,156,161;--color-primary-dark: #3d4145;--color-primary-dark-rgb: 61,65,69;--color-primary-0: #f3f5f6;--color-primary-0-rgb: 246,246,246;--color-primary-50: #e1e2e2;--color-primary-50-rgb: 225,226,226;--color-primary-100: #ccced0;--color-primary-100-rgb: 204,206,208;--color-primary-200: #b0b5b8;--color-primary-200-rgb: 176,181,184;--color-primary-300: #969ca1;--color-primary-300-rgb: 150,156,161;--color-primary-400: #7c848b;--color-primary-400-rgb: 124,132,139;--color-primary-500: #636d75;--color-primary-500-rgb: 99,109,117;--color-primary-600: #50575d;--color-primary-600-rgb: 80,87,93;--color-primary-700: #3d4145;--color-primary-700-rgb: 61,65,69;--color-primary-800: #2b2d2f;--color-primary-800-rgb: 43,45,47;--color-primary-900: #1a1a1a;--color-primary-900-rgb: 26,26,26;--color-accent: #005fb7;--color-accent-rgb: 0,95,183;--color-accent-dark: #183780;--color-accent-dark-rgb: 24,55,128;--color-accent-light: #6795fe;--color-accent-light-rgb: 103,149,254;--color-accent-0: #f5f9ff;--color-accent-0-rgb: 245,249,255;--color-accent-50: #dbe8ff;--color-accent-50-rgb: 219,232,255;--color-accent-100: #c1d7ff;--color-accent-100-rgb: 193,215,255;--color-accent-200: #93b6ff;--color-accent-200-rgb: 147,182,255;--color-accent-300: #6795fe;--color-accent-300-rgb: 103,149,254;--color-accent-400: #3574f8;--color-accent-400-rgb: 53,116,248;--color-accent-500: #005fb7;--color-accent-500-rgb: 0,95,183;--color-accent-600: #144b9b;--color-accent-600-rgb: 20,75,155;--color-accent-700: #183780;--color-accent-700-rgb: 24,55,128;--color-accent-800: #162566;--color-accent-800-rgb: 22,37,102;--color-accent-900: #10144d;--color-accent-900-rgb: 16,20,77;--color-text: #1a1a1a;--color-text-subtle: #50575d;--color-surface: #fff;--color-surface-backdrop: #f6f6f6;--color-link: #005fb7;--color-link-rgb: 0,95,183;--color-link-dark: #183780;--color-link-dark-rgb: 24,55,128;--color-link-light: #6795fe;--color-link-light-rgb: 103,149,254;--color-link-0: #f5f9ff;--color-link-0-rgb: 245,249,255;--color-link-50: #dbe8ff;--color-link-50-rgb: 219,232,255;--color-link-100: #c1d7ff;--color-link-100-rgb: 193,215,255;--color-link-200: #93b6ff;--color-link-200-rgb: 147,182,255;--color-link-300: #6795fe;--color-link-300-rgb: 103,149,254;--color-link-400: #3574f8;--color-link-400-rgb: 53,116,248;--color-link-500: #005fb7;--color-link-500-rgb: 0,95,183;--color-link-600: #144b9b;--color-link-600-rgb: 20,75,155;--color-link-700: #183780;--color-link-700-rgb: 24,55,128;--color-link-800: #162566;--color-link-800-rgb: 22,37,102;--color-link-900: #10144d;--color-link-900-rgb: 16,20,77;--color-button-primary-background-hover: #3574f8;--color-button-primary-scary-background-hover: #ff4b1c;--masterbar-color: #fff;--masterbar-border-color: #3d4145;--masterbar-item-new-editor-background: #636d75;--masterbar-item-new-editor-hover-background: #7c848b;--masterbar-toggle-drafts-editor-background: #7c848b;--masterbar-toggle-drafts-editor-border-color: #ccced0;--masterbar-toggle-drafts-editor-hover-background: #7c848b;--sidebar-background: #e1e2e2;--sidebar-background-gradient: 225,226,226;--sidebar-secondary-background: #fff;--sidebar-secondary-background-gradient: 255,255,255;--sidebar-border-color: #ccced0;--sidebar-gridicon-fill: #636d75;--sidebar-heading-color: #1a1a1a;--sidebar-footer-button-color: #1a1a1a;--sidebar-menu-link-secondary-text-color: #636d75;--sidebar-menu-a-first-child-after-background: 225,226,226;--sidebar-menu-selected-background-color: #50575d;--sidebar-menu-selected-a-color: #fff;--sidebar-menu-selected-a-first-child-after-background: 80,87,93;--sidebar-menu-hover-background: #c1d7ff;--sidebar-menu-hover-background-gradient: 193,215,255;--sidebar-menu-hover-color: #144b9b;--button-is-borderless-color: #636d75;--count-border-color: #636d75;--count-color: #636d75;--profile-gravatar-user-secondary-info-color: #50575d}.color-scheme.is-nightfall{--color-primary: #1a1a1a;--color-primary-light: #969ca1;--color-primary-dark: #3d4145;--color-primary-rgb: 26,26,26;--color-primary-0: #f6f6f6;--color-primary-0-rgb: 246,246,246;--color-primary-50: #e1e2e2;--color-primary-50-rgb: 225,226,226;--color-primary-100: #ccced0;--color-primary-100-rgb: 204,206,208;--color-primary-200: #b0b5b8;--color-primary-200-rgb: 176,181,184;--color-primary-300: #969ca1;--color-primary-300-rgb: 150,156,161;--color-primary-400: #7c848b;--color-primary-400-rgb: 124,132,139;--color-primary-500: #636d75;--color-primary-500-rgb: 99,109,117;--color-primary-600: #50575d;--color-primary-600-rgb: 80,87,93;--color-primary-700: #3d4145;--color-primary-700-rgb: 61,65,69;--color-primary-800: #2b2d2f;--color-primary-800-rgb: 43,45,47;--color-primary-900: #1a1a1a;--color-primary-900-rgb: 26,26,26;--color-accent: #7c589f;--color-accent-rgb: 124,88,159;--color-accent-dark: #4b3264;--color-accent-dark-rgb: 75,50,100;--color-accent-light: #a88ebe;--color-accent-light-rgb: 168,142,190;--color-accent-0: #f7f5f8;--color-accent-0-rgb: 247,245,248;--color-accent-50: #e5deea;--color-accent-50-rgb: 229,222,234;--color-accent-100: #d4c8de;--color-accent-100-rgb: 212,200,222;--color-accent-200: #beabce;--color-accent-200-rgb: 190,171,206;--color-accent-300: #a88ebe;--color-accent-300-rgb: 168,142,190;--color-accent-400: #9273af;--color-accent-400-rgb: 146,115,175;--color-accent-500: #7c589f;--color-accent-500-rgb: 124,88,159;--color-accent-600: #634581;--color-accent-600-rgb: 99,69,129;--color-accent-700: #4b3264;--color-accent-700-rgb: 75,50,100;--color-accent-800: #342148;--color-accent-800-rgb: 52,33,72;--color-accent-900: #1f112e;--color-accent-900-rgb: 31,17,46;--color-text: #2b2d2f;--color-text-subtle: #636d75;--color-surface: #fff;--color-surface-backdrop: #f6f6f6;--color-link: #7c589f;--color-link-rgb: 124,88,159;--color-link-dark: #4b3264;--color-link-dark-rgb: 75,50,100;--color-link-light: #a88ebe;--color-link-light-rgb: 168,142,190;--color-link-0: #f7f5f8;--color-link-0-rgb: 247,245,248;--color-link-50: #e5deea;--color-link-50-rgb: 229,222,234;--color-link-100: #d4c8de;--color-link-100-rgb: 212,200,222;--color-link-200: #beabce;--color-link-200-rgb: 190,171,206;--color-link-300: #a88ebe;--color-link-300-rgb: 168,142,190;--color-link-400: #9273af;--color-link-400-rgb: 146,115,175;--color-link-500: #7c589f;--color-link-500-rgb: 124,88,159;--color-link-600: #634581;--color-link-600-rgb: 99,69,129;--color-link-700: #4b3264;--color-link-700-rgb: 75,50,100;--color-link-800: #342148;--color-link-800-rgb: 52,33,72;--color-link-900: #1f112e;--color-link-900-rgb: 31,17,46;--color-button-primary-background-hover: #9273af;--color-button-primary-scary-background-hover: #ff4b1c;--masterbar-color: #fff;--masterbar-border-color: #3d4145;--masterbar-item-new-editor-background: #636d75;--masterbar-item-new-editor-hover-background: #7c848b;--masterbar-toggle-drafts-editor-background: #7c848b;--masterbar-toggle-drafts-editor-border-color: #ccced0;--masterbar-toggle-drafts-editor-hover-background: #7c848b;--sidebar-background: #204a69;--sidebar-background-gradient: 32,74,105;--sidebar-secondary-background: #fff;--sidebar-secondary-background-gradient: 255,255,255;--sidebar-border-color: #23354b;--sidebar-text-color: #fff;--sidebar-gridicon-fill: #fff;--sidebar-heading-color: #b0b5b8;--sidebar-footer-button-color: #fff;--sidebar-menu-link-secondary-text-color: #fff;--sidebar-menu-a-first-child-after-background: 32,74,105;--sidebar-menu-selected-background-color: #7e280e;--sidebar-menu-selected-a-color: #e1e2e2;--sidebar-menu-selected-a-first-child-after-background: 126,40,14;--sidebar-menu-hover-background: #23354b;--sidebar-menu-hover-background-gradient: 35,53,75;--sidebar-menu-hover-color: #e1e2e2;--button-is-borderless-color: #3d4145;--count-border-color: #3d4145;--count-color: #3d4145;--profile-gravatar-user-secondary-info-color: #e1e2e2}.color-scheme.is-sakura{--color-primary: #195d52;--color-primary-rgb: 25,93,82;--color-primary-light: #438c7d;--color-primary-light-rgb: 67,140,125;--color-primary-dark: #20473f;--color-primary-dark-rgb: 32,71,63;--color-primary-0: #f3f6f5;--color-primary-0-rgb: 243,246,245;--color-primary-50: #d8e3e0;--color-primary-50-rgb: 216,227,224;--color-primary-100: #bad1cb;--color-primary-100-rgb: 186,209,203;--color-primary-200: #93bab0;--color-primary-200-rgb: 147,186,176;--color-primary-300: #6da296;--color-primary-300-rgb: 109,162,150;--color-primary-400: #438c7d;--color-primary-400-rgb: 67,140,125;--color-primary-500: #007565;--color-primary-500-rgb: 0,117,101;--color-primary-600: #195d52;--color-primary-600-rgb: 25,93,82;--color-primary-700: #20473f;--color-primary-700-rgb: 32,71,63;--color-primary-800: #20312d;--color-primary-800-rgb: 32,49,45;--color-primary-900: #1d1d1d;--color-primary-900-rgb: 29,29,29;--color-accent: #005fb7;--color-accent-rgb: 0,95,183;--color-accent-dark: #183780;--color-accent-dark-rgb: 24,55,128;--color-accent-light: #6795fe;--color-accent-light-rgb: 103,149,254;--color-accent-0: #f5f9ff;--color-accent-0-rgb: 245,249,255;--color-accent-50: #dbe8ff;--color-accent-50-rgb: 219,232,255;--color-accent-100: #c1d7ff;--color-accent-100-rgb: 193,215,255;--color-accent-200: #93b6ff;--color-accent-200-rgb: 147,182,255;--color-accent-300: #6795fe;--color-accent-300-rgb: 103,149,254;--color-accent-400: #3574f8;--color-accent-400-rgb: 53,116,248;--color-accent-500: #005fb7;--color-accent-500-rgb: 0,95,183;--color-accent-600: #144b9b;--color-accent-600-rgb: 20,75,155;--color-accent-700: #183780;--color-accent-700-rgb: 24,55,128;--color-accent-800: #162566;--color-accent-800-rgb: 22,37,102;--color-accent-900: #10144d;--color-accent-900-rgb: 16,20,77;--color-text: #1a1a1a;--color-text-subtle: #50575d;--color-surface: #fff;--color-surface-backdrop: #f6f6f6;--color-link: #007565;--color-link-rgb: 0,117,101;--color-link-dark: #20473f;--color-link-dark-rgb: 32,71,63;--color-link-light: #6da296;--color-link-light-rgb: 109,162,150;--color-link-0: #f3f6f5;--color-link-0-rgb: 243,246,245;--color-link-50: #d8e3e0;--color-link-50-rgb: 216,227,224;--color-link-100: #bad1cb;--color-link-100-rgb: 186,209,203;--color-link-200: #93bab0;--color-link-200-rgb: 147,186,176;--color-link-300: #6da296;--color-link-300-rgb: 109,162,150;--color-link-400: #438c7d;--color-link-400-rgb: 67,140,125;--color-link-500: #007565;--color-link-500-rgb: 0,117,101;--color-link-600: #195d52;--color-link-600-rgb: 25,93,82;--color-link-700: #20473f;--color-link-700-rgb: 32,71,63;--color-link-800: #20312d;--color-link-800-rgb: 32,49,45;--color-link-900: #1d1d1d;--color-link-900-rgb: 29,29,29;--color-button-primary-background-hover: #3574f8;--color-button-primary-scary-background-hover: #ff4b1c;--masterbar-color: #fff;--masterbar-border-color: #20473f;--masterbar-item-new-editor-background: #636d75;--masterbar-item-new-editor-hover-background: #50575d;--masterbar-toggle-drafts-editor-background: #50575d;--masterbar-toggle-drafts-editor-border-color: #ccced0;--masterbar-toggle-drafts-editor-hover-background: #7c848b;--sidebar-background: #ebc6d5;--sidebar-background-gradient: 235,198,213;--sidebar-secondary-background: #fff;--sidebar-secondary-background-gradient: 255,255,255;--sidebar-border-color: #e1a7bf;--sidebar-text-color: #5d283d;--sidebar-gridicon-fill: #9b3c69;--sidebar-heading-color: #7b3252;--sidebar-footer-button-color: #1a1a1a;--sidebar-menu-link-secondary-text-color: #7b3252;--sidebar-menu-a-first-child-after-background: 235,198,213;--sidebar-menu-selected-background-color: #dbe8ff;--sidebar-menu-selected-a-color: #144b9b;--sidebar-menu-selected-a-first-child-after-background: 219,232,255;--sidebar-menu-hover-background: #c96895;--sidebar-menu-hover-background-gradient: 201,104,149;--sidebar-menu-hover-color: #fff;--button-is-borderless-color: #636d75;--count-border-color: #636d75;--count-color: #636d75;--profile-gravatar-user-secondary-info-color: #7b3252}.color-scheme.is-laser-black{--color-primary: #005fb7;--color-primary-light: #3574f8;--color-primary-dark: #183780;--color-accent: #ff3997;--color-accent-light: #ffa2d4;--color-accent-dark: #b7266a;--color-white: #000;--color-white-rgb: 0,0,0;--color-neutral: #636d75;--color-neutral-rgb: 99,109,117;--color-neutral-dark: #3d4145;--color-neutral-dark-rgb: 61,65,69;--color-neutral-light: #969ca1;--color-neutral-light-rgb: 150,156,161;--color-neutral-0: #1a1a1a;--color-neutral-0-rgb: 26,26,26;--color-neutral-50: #2b2d2f;--color-neutral-50-rgb: 43,45,47;--color-neutral-100: #3d4145;--color-neutral-100-rgb: 61,65,69;--color-neutral-200: #50575d;--color-neutral-200-rgb: 80,87,93;--color-neutral-300: #636d75;--color-neutral-300-rgb: 99,109,117;--color-neutral-400: #7c848b;--color-neutral-400-rgb: 124,132,139;--color-neutral-500: #969ca1;--color-neutral-500-rgb: 150,156,161;--color-neutral-600: #b0b5b8;--color-neutral-600-rgb: 176,181,184;--color-neutral-700: #ccced0;--color-neutral-700-rgb: 204,206,208;--color-neutral-800: #e1e2e2;--color-neutral-800-rgb: 225,226,226;--color-neutral-900: #f6f6f6;--color-neutral-900-rgb: 246,246,246;--color-success: #44a234;--color-success-light: #9dcf8d;--color-success-dark: #08720b;--color-warning: #f6c200;--color-warning-light: #fbe697;--color-warning-dark: #daaa12;--color-error: #ff4b1c;--color-error-light: #ffab78;--color-error-dark: #cb0c07;--color-text: #ccced0;--color-text-subtle: #969ca1;--color-surface: #000;--color-surface-backdrop: #1a1a1a;--color-surface-backdrop-rgb: 26,26,26;--masterbar-color: #fff;--masterbar-border-color: #b0b5b8;--masterbar-item-new-editor-background: #636d75;--masterbar-item-new-editor-hover-background: #7c848b;--masterbar-toggle-drafts-editor-background: #7c848b;--masterbar-toggle-drafts-editor-border-color: #ccced0;--masterbar-toggle-drafts-editor-hover-background: #7c848b;--sidebar-background: #1a1a1a;--sidebar-background-gradient: 26,26,26;--sidebar-secondary-background: #1a1a1a;--sidebar-secondary-background-gradient: 26,26,26;--sidebar-text-color: #ccced0;--sidebar-gridicon-fill: #7c848b;--sidebar-heading-color: #7c848b;--sidebar-footer-button-color: #3d4145;--sidebar-menu-link-secondary-text-color: #3d4145;--sidebar-menu-a-first-child-after-background: 26,26,26;--sidebar-menu-selected-background-color: #183780;--sidebar-menu-selected-a-color: #93b6ff;--sidebar-menu-selected-a-first-child-after-background: 24,55,128;--sidebar-menu-hover-background: #3d4145;--sidebar-menu-hover-background-gradient: 61,65,69;--sidebar-menu-hover-color: #ccced0;--profile-gravatar-user-secondary-info-color: #3d4145}.wp-core-ui.wp-admin .wcc-root{/*!rtl:ignore*//*!rtl:ignore*//*!rtl:ignore*/}.wp-core-ui.wp-admin .wcc-root a,.wp-core-ui.wp-admin .wcc-root a:visited{text-decoration:none}.wp-core-ui.wp-admin .wcc-root .button{background:#f6f6f6;box-shadow:none;padding:5px 14px 7px}.wp-core-ui.wp-admin .wcc-root .button .spinner{margin-bottom:-8px}.wp-core-ui.wp-admin .wcc-root .button .spinner .spinner__border{fill:transparent}.wp-core-ui.wp-admin .wcc-root .label-settings__credit-card-description button.is-borderless{color:#016087}.wp-core-ui.wp-admin .wcc-root .button.is-primary{background:#016087;border-color:#23354b}.wp-core-ui.wp-admin .wcc-root .button.is-primary:hover{background:#016087}.wp-core-ui.wp-admin .wcc-root .button.is-primary[disabled],.wp-core-ui.wp-admin .wcc-root .button.is-primary:disabled,.wp-core-ui.wp-admin .wcc-root .button.is-primary.disabled{color:#f6f6f6 !important;background:#fff !important;border-color:#f6f6f6 !important;text-shadow:none !important}.wp-core-ui.wp-admin .wcc-root .button.is-primary.is-busy{background-size:120px 100% !important;background-image:linear-gradient(-45deg, #016087 28%, #46799a 28%, #46799a 72%, #016087 72%) !important;border-color:#0081a9 !important}.wp-core-ui.wp-admin .wcc-root .button.is-primary.is-borderless{background:none}.wp-core-ui.wp-admin .wcc-root input[type=checkbox]:checked:before{font-family:initial;font-size:16px;font-weight:600;line-height:0px;float:none}.wp-core-ui.wp-admin .wcc-root input[type='text'],.wp-core-ui.wp-admin .wcc-root input[type='search'],.wp-core-ui.wp-admin .wcc-root input[type='email'],.wp-core-ui.wp-admin .wcc-root input[type='number'],.wp-core-ui.wp-admin .wcc-root input[type='password'],.wp-core-ui.wp-admin .wcc-root input[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input[type='radio'],.wp-core-ui.wp-admin .wcc-root input[type='tel'],.wp-core-ui.wp-admin .wcc-root input[type='url'],.wp-core-ui.wp-admin .wcc-root textarea{box-shadow:none;height:auto}.wp-core-ui.wp-admin .wcc-root input[type='text']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='search']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='email']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='number']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='password']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='checkbox']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='radio']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='tel']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root input[type='url']:-ms-input-placeholder,.wp-core-ui.wp-admin .wcc-root textarea:-ms-input-placeholder{color:#b0b5b8}.wp-core-ui.wp-admin .wcc-root input[type='text']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='search']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='email']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='number']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='password']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='checkbox']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='radio']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='tel']::placeholder,.wp-core-ui.wp-admin .wcc-root input[type='url']::placeholder,.wp-core-ui.wp-admin .wcc-root textarea::placeholder{color:#b0b5b8}.wp-core-ui.wp-admin .wcc-root .form-input-validation{padding:4px 0 4px 32px}.wp-core-ui.wp-admin .wcc-root .form-input-validation .gridicon{float:none;vertical-align:middle}.wp-core-ui.wp-admin .wcc-root .form-server-error .gridicon{float:none;vertical-align:middle}.wp-core-ui.wp-admin .wcc-root .settings-steps-summary{display:flex;flex-wrap:wrap;justify-content:space-between}.wp-core-ui.wp-admin .wcc-root .settings-steps-summary .settings-step-summary{background-color:#f6f6f6;border-radius:5px;border:1px #3d4145 solid;padding:12px;margin-bottom:12px;flex-basis:44%}.wp-core-ui.wp-admin .wcc-root .settings-steps-summary .settings-step-summary h4{font-weight:bold}.wp-core-ui.wp-admin .wcc-root .share-package-option{display:inline-block;margin-top:8px;text-align:left;font-size:13px}.wp-core-ui.wp-admin .wcc-root .global-notices{z-index:999999 !important;top:16px;right:16px}@media (max-width: 660px){.wp-core-ui.wp-admin .wcc-root .global-notices{top:-5px;right:0}}.wp-core-ui.wp-admin .wcc-root .global-notices .notice{max-width:740px}@media (max-width: 660px){.wp-core-ui.wp-admin .wcc-root .global-notices .notice{margin-left:0}}.wp-core-ui.wp-admin .wcc-root .global-notices .notice__text{font-size:15px}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .global-notices .notice__text{margin-top:1px}}.wp-core-ui.wp-admin .wcc-root:not(.label-purchase-modal){max-width:100%;padding:20px;position:relative}.wp-core-ui.wp-admin .wcc-root.wc-connect-shipping-settings{margin-top:6px}.wp-core-ui.wp-admin .wcc-root .card{min-width:0;max-width:none}.wp-core-ui.wp-admin .wcc-root select{height:auto;box-shadow:none;width:100%;line-height:18px;padding:9px 32px 12px 14px}.wp-core-ui.wp-admin .wcc-root .button{height:auto}.wp-core-ui.wp-admin .wcc-root .button:focus{box-shadow:none}.wp-core-ui.wp-admin .wcc-root .spinner{background:none;visibility:visible;float:none;vertical-align:inherit;opacity:1;width:inherit;height:inherit}@keyframes fadeIn{from{opacity:0}to{opacity:1}}.wp-core-ui.wp-admin .wcc-root .form-troubles{opacity:0;animation:fadeIn ease-in 1;animation-fill-mode:forwards;animation-duration:.5s;animation-delay:3s}.wp-core-ui.wp-admin .wcc-root .wc-connect-no-priv-settings{background:#fff;padding:20px}.wp-core-ui.wp-admin .wcc-root .gridicon{fill:currentColor}.wp-core-ui.wp-admin .wcc-root .label-settings__labels-container .label-settings__external{display:block !important}.wp-core-ui.wp-admin .wcc-root .label-settings__labels-container .label-settings__internal{display:none}.wp-core-ui.wp-admin .wcc-root html,.wp-core-ui.wp-admin .wcc-root body,.wp-core-ui.wp-admin .wcc-root div,.wp-core-ui.wp-admin .wcc-root span,.wp-core-ui.wp-admin .wcc-root applet,.wp-core-ui.wp-admin .wcc-root object,.wp-core-ui.wp-admin .wcc-root iframe,.wp-core-ui.wp-admin .wcc-root h1,.wp-core-ui.wp-admin .wcc-root h2,.wp-core-ui.wp-admin .wcc-root h3,.wp-core-ui.wp-admin .wcc-root h4,.wp-core-ui.wp-admin .wcc-root h5,.wp-core-ui.wp-admin .wcc-root h6,.wp-core-ui.wp-admin .wcc-root p,.wp-core-ui.wp-admin .wcc-root blockquote,.wp-core-ui.wp-admin .wcc-root pre,.wp-core-ui.wp-admin .wcc-root a,.wp-core-ui.wp-admin .wcc-root abbr,.wp-core-ui.wp-admin .wcc-root acronym,.wp-core-ui.wp-admin .wcc-root address,.wp-core-ui.wp-admin .wcc-root big,.wp-core-ui.wp-admin .wcc-root cite,.wp-core-ui.wp-admin .wcc-root code,.wp-core-ui.wp-admin .wcc-root del,.wp-core-ui.wp-admin .wcc-root dfn,.wp-core-ui.wp-admin .wcc-root em,.wp-core-ui.wp-admin .wcc-root font,.wp-core-ui.wp-admin .wcc-root ins,.wp-core-ui.wp-admin .wcc-root kbd,.wp-core-ui.wp-admin .wcc-root q,.wp-core-ui.wp-admin .wcc-root s,.wp-core-ui.wp-admin .wcc-root samp,.wp-core-ui.wp-admin .wcc-root small,.wp-core-ui.wp-admin .wcc-root strike,.wp-core-ui.wp-admin .wcc-root strong,.wp-core-ui.wp-admin .wcc-root sub,.wp-core-ui.wp-admin .wcc-root sup,.wp-core-ui.wp-admin .wcc-root tt,.wp-core-ui.wp-admin .wcc-root var,.wp-core-ui.wp-admin .wcc-root dl,.wp-core-ui.wp-admin .wcc-root dt,.wp-core-ui.wp-admin .wcc-root dd,.wp-core-ui.wp-admin .wcc-root ol,.wp-core-ui.wp-admin .wcc-root ul,.wp-core-ui.wp-admin .wcc-root li,.wp-core-ui.wp-admin .wcc-root fieldset,.wp-core-ui.wp-admin .wcc-root form,.wp-core-ui.wp-admin .wcc-root label,.wp-core-ui.wp-admin .wcc-root legend,.wp-core-ui.wp-admin .wcc-root table,.wp-core-ui.wp-admin .wcc-root caption,.wp-core-ui.wp-admin .wcc-root tbody,.wp-core-ui.wp-admin .wcc-root tfoot,.wp-core-ui.wp-admin .wcc-root thead,.wp-core-ui.wp-admin .wcc-root tr,.wp-core-ui.wp-admin .wcc-root th,.wp-core-ui.wp-admin .wcc-root td{border:0;font-family:inherit;font-size:100%;font-style:inherit;font-weight:inherit;margin:0;outline:0;padding:0;vertical-align:baseline}.wp-core-ui.wp-admin .wcc-root html{overflow-y:scroll;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}.wp-core-ui.wp-admin .wcc-root body{background:#fff}.wp-core-ui.wp-admin .wcc-root article,.wp-core-ui.wp-admin .wcc-root aside,.wp-core-ui.wp-admin .wcc-root details,.wp-core-ui.wp-admin .wcc-root figcaption,.wp-core-ui.wp-admin .wcc-root figure,.wp-core-ui.wp-admin .wcc-root footer,.wp-core-ui.wp-admin .wcc-root header,.wp-core-ui.wp-admin .wcc-root hgroup,.wp-core-ui.wp-admin .wcc-root main,.wp-core-ui.wp-admin .wcc-root nav,.wp-core-ui.wp-admin .wcc-root section{display:block}.wp-core-ui.wp-admin .wcc-root ol,.wp-core-ui.wp-admin .wcc-root ul{list-style:none}.wp-core-ui.wp-admin .wcc-root table{border-collapse:separate;border-spacing:0}.wp-core-ui.wp-admin .wcc-root caption,.wp-core-ui.wp-admin .wcc-root th,.wp-core-ui.wp-admin .wcc-root td{font-weight:normal;text-align:left}.wp-core-ui.wp-admin .wcc-root blockquote::before,.wp-core-ui.wp-admin .wcc-root blockquote::after,.wp-core-ui.wp-admin .wcc-root q::before,.wp-core-ui.wp-admin .wcc-root q::after{content:''}.wp-core-ui.wp-admin .wcc-root blockquote,.wp-core-ui.wp-admin .wcc-root q{quotes:'' ''}.wp-core-ui.wp-admin .wcc-root a:focus{outline:thin dotted}.wp-core-ui.wp-admin .wcc-root a:hover,.wp-core-ui.wp-admin .wcc-root a:active{outline:0}.wp-core-ui.wp-admin .wcc-root a img{border:0}.wp-core-ui.wp-admin .wcc-root input,.wp-core-ui.wp-admin .wcc-root textarea{border-radius:0;-webkit-appearance:none;-moz-appearance:none;appearance:none}.wp-core-ui.wp-admin .wcc-root input[type='radio'],.wp-core-ui.wp-admin .wcc-root input[type='checkbox']{-webkit-appearance:none}.wp-core-ui.wp-admin .wcc-root fieldset,.wp-core-ui.wp-admin .wcc-root input[type='text'],.wp-core-ui.wp-admin .wcc-root input[type='search'],.wp-core-ui.wp-admin .wcc-root input[type='email'],.wp-core-ui.wp-admin .wcc-root input[type='number'],.wp-core-ui.wp-admin .wcc-root input[type='password'],.wp-core-ui.wp-admin .wcc-root input[type='tel'],.wp-core-ui.wp-admin .wcc-root input[type='url'],.wp-core-ui.wp-admin .wcc-root textarea,.wp-core-ui.wp-admin .wcc-root select,.wp-core-ui.wp-admin .wcc-root label{box-sizing:border-box}.wp-core-ui.wp-admin .wcc-root input[type='password'],.wp-core-ui.wp-admin .wcc-root input[type='email'],.wp-core-ui.wp-admin .wcc-root input[type='url']{/*!rtl:ignore*/direction:ltr}.wp-core-ui.wp-admin .wcc-root input[type='checkbox'],.wp-core-ui.wp-admin .wcc-root input[type='radio']{clear:none;cursor:pointer;display:inline-block;line-height:0;height:16px;margin:2px 0 0;float:left;outline:0;padding:0;text-align:center;vertical-align:middle;width:16px;min-width:16px;-webkit-appearance:none;-moz-appearance:none;appearance:none}.wp-core-ui.wp-admin .wcc-root input[type='checkbox']+span,.wp-core-ui.wp-admin .wcc-root input[type='radio']+span{display:block;margin-left:24px}.wp-core-ui.wp-admin .wcc-root input[type='checkbox']{border-radius:2px}.wp-core-ui.wp-admin .wcc-root input[type='checkbox']:checked::before{content:url("https://wordpress.com//calypso/images/checkbox-icons/checkmark-primary.svg");width:12px;height:12px;margin:1px auto;display:inline-block;speak:none}.wp-core-ui.wp-admin .wcc-root input[type='checkbox']:disabled:checked::before{color:#b0b5b8}.wp-core-ui.wp-admin .wcc-root input[type='radio']{border-radius:50%;margin-right:4px;line-height:10px}.wp-core-ui.wp-admin .wcc-root input[type='radio']:checked::before{float:left;display:inline-block;content:'\2022';margin:3px;width:8px;height:8px;text-indent:-9999px;background:#016087;vertical-align:middle;border-radius:50%;animation:grow 0.2s ease-in-out}.wp-core-ui.wp-admin .wcc-root input[type='radio']:disabled:checked::before{background:#f6f6f6}@keyframes grow{0%{transform:scale(0.3)}60%{transform:scale(1.15)}100%{transform:scale(1)}}@keyframes grow{0%{transform:scale(0.3)}60%{transform:scale(1.15)}100%{transform:scale(1)}}.wp-core-ui.wp-admin .wcc-root select{background:#fff url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIj8+PHN2ZyB3aWR0aD0iMjBweCIgaGVpZ2h0PSIyMHB4IiB2aWV3Qm94PSIwIDAgMjAgMjAiIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeG1sbnM6c2tldGNoPSJodHRwOi8vd3d3LmJvaGVtaWFuY29kaW5nLmNvbS9za2V0Y2gvbnMiPiAgICAgICAgPHRpdGxlPmFycm93LWRvd248L3RpdGxlPiAgICA8ZGVzYz5DcmVhdGVkIHdpdGggU2tldGNoLjwvZGVzYz4gICAgPGRlZnM+PC9kZWZzPiAgICA8ZyBpZD0iUGFnZS0xIiBzdHJva2U9Im5vbmUiIHN0cm9rZS13aWR0aD0iMSIgZmlsbD0ibm9uZSIgZmlsbC1ydWxlPSJldmVub2RkIiBza2V0Y2g6dHlwZT0iTVNQYWdlIj4gICAgICAgIDxnIGlkPSJhcnJvdy1kb3duIiBza2V0Y2g6dHlwZT0iTVNBcnRib2FyZEdyb3VwIiBmaWxsPSIjQzhEN0UxIj4gICAgICAgICAgICA8cGF0aCBkPSJNMTUuNSw2IEwxNyw3LjUgTDEwLjI1LDE0LjI1IEwzLjUsNy41IEw1LDYgTDEwLjI1LDExLjI1IEwxNS41LDYgWiIgaWQ9IkRvd24tQXJyb3ciIHNrZXRjaDp0eXBlPSJNU1NoYXBlR3JvdXAiPjwvcGF0aD4gICAgICAgIDwvZz4gICAgPC9nPjwvc3ZnPg==) no-repeat right 10px center;border-color:#ccced0;border-style:solid;border-radius:4px;border-width:1px 1px 2px;color:#3d4145;cursor:pointer;display:inline-block;margin:0;outline:0;overflow:hidden;font-size:16px;font-weight:400;line-height:1.4em;text-overflow:ellipsis;text-decoration:none;vertical-align:top;white-space:nowrap;box-sizing:border-box;padding:7px 32px 9px 14px;-webkit-appearance:none;-moz-appearance:none;appearance:none}.wp-core-ui.wp-admin .wcc-root select:hover{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIj8+PHN2ZyB3aWR0aD0iMjBweCIgaGVpZ2h0PSIyMHB4IiB2aWV3Qm94PSIwIDAgMjAgMjAiIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeG1sbnM6c2tldGNoPSJodHRwOi8vd3d3LmJvaGVtaWFuY29kaW5nLmNvbS9za2V0Y2gvbnMiPiAgICAgICAgPHRpdGxlPmFycm93LWRvd248L3RpdGxlPiAgICA8ZGVzYz5DcmVhdGVkIHdpdGggU2tldGNoLjwvZGVzYz4gICAgPGRlZnM+PC9kZWZzPiAgICA8ZyBpZD0iUGFnZS0xIiBzdHJva2U9Im5vbmUiIHN0cm9rZS13aWR0aD0iMSIgZmlsbD0ibm9uZSIgZmlsbC1ydWxlPSJldmVub2RkIiBza2V0Y2g6dHlwZT0iTVNQYWdlIj4gICAgICAgIDxnIGlkPSJhcnJvdy1kb3duIiBza2V0Y2g6dHlwZT0iTVNBcnRib2FyZEdyb3VwIiBmaWxsPSIjYThiZWNlIj4gICAgICAgICAgICA8cGF0aCBkPSJNMTUuNSw2IEwxNyw3LjUgTDEwLjI1LDE0LjI1IEwzLjUsNy41IEw1LDYgTDEwLjI1LDExLjI1IEwxNS41LDYgWiIgaWQ9IkRvd24tQXJyb3ciIHNrZXRjaDp0eXBlPSJNU1NoYXBlR3JvdXAiPjwvcGF0aD4gICAgICAgIDwvZz4gICAgPC9nPjwvc3ZnPg==)}.wp-core-ui.wp-admin .wcc-root select:focus{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIj8+PHN2ZyB3aWR0aD0iMjBweCIgaGVpZ2h0PSIyMHB4IiB2aWV3Qm94PSIwIDAgMjAgMjAiIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeG1sbnM6c2tldGNoPSJodHRwOi8vd3d3LmJvaGVtaWFuY29kaW5nLmNvbS9za2V0Y2gvbnMiPiA8dGl0bGU+YXJyb3ctZG93bjwvdGl0bGU+IDxkZXNjPkNyZWF0ZWQgd2l0aCBTa2V0Y2guPC9kZXNjPiA8ZGVmcz48L2RlZnM+IDxnIGlkPSJQYWdlLTEiIHN0cm9rZT0ibm9uZSIgc3Ryb2tlLXdpZHRoPSIxIiBmaWxsPSJub25lIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiIHNrZXRjaDp0eXBlPSJNU1BhZ2UiPiA8ZyBpZD0iYXJyb3ctZG93biIgc2tldGNoOnR5cGU9Ik1TQXJ0Ym9hcmRHcm91cCIgZmlsbD0iIzJlNDQ1MyI+IDxwYXRoIGQ9Ik0xNS41LDYgTDE3LDcuNSBMMTAuMjUsMTQuMjUgTDMuNSw3LjUgTDUsNiBMMTAuMjUsMTEuMjUgTDE1LjUsNiBaIiBpZD0iRG93bi1BcnJvdyIgc2tldGNoOnR5cGU9Ik1TU2hhcGVHcm91cCI+PC9wYXRoPiA8L2c+IDwvZz48L3N2Zz4=);border-color:#016087;box-shadow:0 0 0 2px #bbc9d5;outline:0;-moz-outline:none;-moz-user-focus:ignore}.wp-core-ui.wp-admin .wcc-root select:disabled,.wp-core-ui.wp-admin .wcc-root select:hover:disabled{background:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIj8+PHN2ZyB3aWR0aD0iMjBweCIgaGVpZ2h0PSIyMHB4IiB2aWV3Qm94PSIwIDAgMjAgMjAiIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeG1sbnM6c2tldGNoPSJodHRwOi8vd3d3LmJvaGVtaWFuY29kaW5nLmNvbS9za2V0Y2gvbnMiPiAgICAgICAgPHRpdGxlPmFycm93LWRvd248L3RpdGxlPiAgICA8ZGVzYz5DcmVhdGVkIHdpdGggU2tldGNoLjwvZGVzYz4gICAgPGRlZnM+PC9kZWZzPiAgICA8ZyBpZD0iUGFnZS0xIiBzdHJva2U9Im5vbmUiIHN0cm9rZS13aWR0aD0iMSIgZmlsbD0ibm9uZSIgZmlsbC1ydWxlPSJldmVub2RkIiBza2V0Y2g6dHlwZT0iTVNQYWdlIj4gICAgICAgIDxnIGlkPSJhcnJvdy1kb3duIiBza2V0Y2g6dHlwZT0iTVNBcnRib2FyZEdyb3VwIiBmaWxsPSIjZTllZmYzIj4gICAgICAgICAgICA8cGF0aCBkPSJNMTUuNSw2IEwxNyw3LjUgTDEwLjI1LDE0LjI1IEwzLjUsNy41IEw1LDYgTDEwLjI1LDExLjI1IEwxNS41LDYgWiIgaWQ9IkRvd24tQXJyb3ciIHNrZXRjaDp0eXBlPSJNU1NoYXBlR3JvdXAiPjwvcGF0aD4gICAgICAgIDwvZz4gICAgPC9nPjwvc3ZnPg==) no-repeat right 10px center}.wp-core-ui.wp-admin .wcc-root select.is-compact{min-width:0;padding:0 20px 2px 6px;margin:0 4px;background-position:right 5px center;background-size:12px 12px}label .wp-core-ui.wp-admin .wcc-root select,label+.wp-core-ui.wp-admin .wcc-root select{display:block;min-width:200px}label .wp-core-ui.wp-admin .wcc-root select.is-compact,label+.wp-core-ui.wp-admin .wcc-root select.is-compact{display:inline-block;min-width:0}.wp-core-ui.wp-admin .wcc-root select::-ms-expand{display:none}.wp-core-ui.wp-admin .wcc-root select::-ms-value{background:none;color:#3d4145}.wp-core-ui.wp-admin .wcc-root select:-moz-focusring{color:transparent;text-shadow:0 0 0 #3d4145}.wp-core-ui.wp-admin .wcc-root input[type='search']::-webkit-search-decoration{display:none}.wp-core-ui.wp-admin .wcc-root .wpcom-site__logo{fill:#ccced0;position:fixed;top:50%;left:50%;transform:translate(-50%, -50%)}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .wpcom-site__logo{width:100px;height:100px}}.wp-core-ui.wp-admin .wcc-root .wpcom-site__global-noscript{position:fixed;bottom:0;left:0;right:0;padding:6px;color:#fff;background:rgba(61,65,69, 0.8);text-align:center;z-index:300000}@-webkit-viewport{.wp-core-ui.wp-admin .wcc-root{width:device-width}}@-moz-viewport{.wp-core-ui.wp-admin .wcc-root{width:device-width}}@-ms-viewport{.wp-core-ui.wp-admin .wcc-root{width:device-width}}@viewport{.wp-core-ui.wp-admin .wcc-root{width:device-width}}.wp-core-ui.wp-admin .wcc-root html,.wp-core-ui.wp-admin .wcc-root body,.wp-core-ui.wp-admin .wcc-root .wpcom-site{height:100%}.wp-core-ui.wp-admin .wcc-root *{-webkit-tap-highlight-color:rgba(0,0,0,0)}.wp-core-ui.wp-admin .wcc-root body{background:#f6f6f6;color:#2b2d2f;font-size:15px;line-height:1.5;-ms-overflow-style:scrollbar}@media (max-width: 660px){.wp-core-ui.wp-admin .wcc-root body{cursor:pointer}}.wp-core-ui.wp-admin .wcc-root ::selection{background:rgba(111,147,173, 0.7);color:#2b2d2f}.wp-core-ui.wp-admin .wcc-root body,.wp-core-ui.wp-admin .wcc-root button,.wp-core-ui.wp-admin .wcc-root input,.wp-core-ui.wp-admin .wcc-root select,.wp-core-ui.wp-admin .wcc-root textarea,.wp-core-ui.wp-admin .wcc-root .button,.wp-core-ui.wp-admin .wcc-root #footer,.wp-core-ui.wp-admin .wcc-root #footer a.readmore{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif}.wp-core-ui.wp-admin .wcc-root body.rtl,.wp-core-ui.wp-admin .wcc-root .rtl button,.wp-core-ui.wp-admin .wcc-root .rtl input,.wp-core-ui.wp-admin .wcc-root .rtl select,.wp-core-ui.wp-admin .wcc-root .rtl textarea,.wp-core-ui.wp-admin .wcc-root .rtl .button,.wp-core-ui.wp-admin .wcc-root .rtl #footer,.wp-core-ui.wp-admin .wcc-root .rtl #footer a.readmore{font-family:Tahoma,-apple-system,BlinkMacSystemFont,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif}.wp-core-ui.wp-admin .wcc-root :lang(he) body.rtl,.wp-core-ui.wp-admin .wcc-root :lang(he) .rtl button,.wp-core-ui.wp-admin .wcc-root :lang(he) .rtl input,.wp-core-ui.wp-admin .wcc-root :lang(he) .rtl select,.wp-core-ui.wp-admin .wcc-root :lang(he) .rtl textarea,.wp-core-ui.wp-admin .wcc-root :lang(he) .rtl .button,.wp-core-ui.wp-admin .wcc-root :lang(he) .rtl #footer,.wp-core-ui.wp-admin .wcc-root :lang(he) .rtl #footer a.readmore{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif}.wp-core-ui.wp-admin .wcc-root .rtl .gridicon.gridicons-chevron-left,.wp-core-ui.wp-admin .wcc-root .rtl .gridicon.gridicons-chevron-right,.wp-core-ui.wp-admin .wcc-root .rtl .gridicon.gridicons-arrow-left,.wp-core-ui.wp-admin .wcc-root .rtl .gridicon.gridicons-arrow-right,.wp-core-ui.wp-admin .wcc-root .rtl .gridicon.gridicons-external,.wp-core-ui.wp-admin .wcc-root .rtl .gridicon.gridicons-cart{transform:scaleX(-1)}.wp-core-ui.wp-admin .wcc-root .notifications{display:inherit}.wp-core-ui.wp-admin .wcc-root noscript{text-align:center;margin-top:3em;display:block}.wp-core-ui.wp-admin .wcc-root h1,.wp-core-ui.wp-admin .wcc-root h2,.wp-core-ui.wp-admin .wcc-root h3,.wp-core-ui.wp-admin .wcc-root h4,.wp-core-ui.wp-admin .wcc-root h5,.wp-core-ui.wp-admin .wcc-root h6{clear:both}.wp-core-ui.wp-admin .wcc-root hr{background:#ccced0;border:0;height:1px;margin-bottom:1.5em}.wp-core-ui.wp-admin .wcc-root p{margin-bottom:1.5em}.wp-core-ui.wp-admin .wcc-root ul,.wp-core-ui.wp-admin .wcc-root ol{margin:0 0 1.5em 3em}.wp-core-ui.wp-admin .wcc-root ul{list-style:disc}.wp-core-ui.wp-admin .wcc-root ol{list-style:decimal}.wp-core-ui.wp-admin .wcc-root ul ul,.wp-core-ui.wp-admin .wcc-root ol ol,.wp-core-ui.wp-admin .wcc-root ul ol,.wp-core-ui.wp-admin .wcc-root ol ul{margin-bottom:0;margin-left:1.5em}.wp-core-ui.wp-admin .wcc-root dt{font-weight:600}.wp-core-ui.wp-admin .wcc-root dd{margin:0 1.5em 1.5em}.wp-core-ui.wp-admin .wcc-root b,.wp-core-ui.wp-admin .wcc-root strong{font-weight:600}.wp-core-ui.wp-admin .wcc-root dfn,.wp-core-ui.wp-admin .wcc-root cite,.wp-core-ui.wp-admin .wcc-root em,.wp-core-ui.wp-admin .wcc-root i{font-style:italic}.wp-core-ui.wp-admin .wcc-root blockquote{margin:10px 0 0;background:#f6f6f6;padding:10px 10px 1px;border-radius:2px}.wp-core-ui.wp-admin .wcc-root address{margin:0 0 1.5em}.wp-core-ui.wp-admin .wcc-root pre{background:#f6f6f6;font-family:"Courier 10 Pitch",Courier,monospace;font-size:15px;line-height:1.6;margin-bottom:1.6em;padding:1.6em;overflow:auto;max-width:100%}.wp-core-ui.wp-admin .wcc-root code,.wp-core-ui.wp-admin .wcc-root kbd,.wp-core-ui.wp-admin .wcc-root tt,.wp-core-ui.wp-admin .wcc-root var{font:15px Monaco,Consolas,"Andale Mono","DejaVu Sans Mono","Courier 10 Pitch",Courier,monospace}.wp-core-ui.wp-admin .wcc-root abbr,.wp-core-ui.wp-admin .wcc-root acronym{border-bottom:1px dotted #ccced0;cursor:help;text-decoration:none}.wp-core-ui.wp-admin .wcc-root mark,.wp-core-ui.wp-admin .wcc-root ins{background:#fbda70;text-decoration:none}.wp-core-ui.wp-admin .wcc-root small{font-size:75%}.wp-core-ui.wp-admin .wcc-root big{font-size:125%}.wp-core-ui.wp-admin .wcc-root figure{margin:0}.wp-core-ui.wp-admin .wcc-root table{margin:0 0 1.5em;width:100%}.wp-core-ui.wp-admin .wcc-root th{font-weight:600}.wp-core-ui.wp-admin .wcc-root .hide,.wp-core-ui.wp-admin .wcc-root .hidden{display:none}.wp-core-ui.wp-admin .wcc-root a,.wp-core-ui.wp-admin .wcc-root a:visited{color:#016087}.wp-core-ui.wp-admin .wcc-root a:hover,.wp-core-ui.wp-admin .wcc-root a:focus,.wp-core-ui.wp-admin .wcc-root a:active{color:#23354b}.wp-core-ui.wp-admin .wcc-root .link--caution,.wp-core-ui.wp-admin .wcc-root .link--caution:hover,.wp-core-ui.wp-admin .wcc-root .link--caution:focus,.wp-core-ui.wp-admin .wcc-root .link--caution:active,.wp-core-ui.wp-admin .wcc-root .link--caution:visited,.wp-core-ui.wp-admin .wcc-root .link--caution:visited:hover,.wp-core-ui.wp-admin .wcc-root .link--caution:visited:focus,.wp-core-ui.wp-admin .wcc-root .link--caution:visited:active,.wp-core-ui.wp-admin .wcc-root .is-link.link--caution,.wp-core-ui.wp-admin .wcc-root .is-link.link--caution:hover,.wp-core-ui.wp-admin .wcc-root .is-link.link--caution:focus,.wp-core-ui.wp-admin .wcc-root .is-link.link--caution:active,.wp-core-ui.wp-admin .wcc-root .is-link.link--caution:visited,.wp-core-ui.wp-admin .wcc-root .is-link.link--caution:visited:hover,.wp-core-ui.wp-admin .wcc-root .is-link.link--caution:visited:focus,.wp-core-ui.wp-admin .wcc-root .is-link.link--caution:visited:active{color:#eb0001}.wp-core-ui.wp-admin .wcc-root html.iframed{overflow:hidden}.wp-core-ui.wp-admin .wcc-root img.emoji,.wp-core-ui.wp-admin .wcc-root img.wp-smiley{height:1em;max-height:1em;display:inline;margin:0;padding:0 0.2em;vertical-align:-0.1em;width:1em}.wp-core-ui.wp-admin .wcc-root img{max-width:100%;height:auto}.wp-core-ui.wp-admin .wcc-root embed,.wp-core-ui.wp-admin .wcc-root iframe,.wp-core-ui.wp-admin .wcc-root object{max-width:100%}.wp-core-ui.wp-admin .wcc-root .wpcom-soundcloud-player,.wp-core-ui.wp-admin .wcc-root .embed-soundcloud iframe{min-height:150px}.wp-core-ui.wp-admin .wcc-root html.no-scroll{overflow:hidden}.wp-core-ui.wp-admin .wcc-root button{background:transparent;border:none;outline:0;padding:0;font-size:14px;-webkit-appearance:none;-moz-appearance:none;appearance:none;vertical-align:baseline}.wp-core-ui.wp-admin .wcc-root .button{border-style:solid;border-width:1px 1px 2px;cursor:pointer;display:inline-block;margin:0;outline:0;overflow:hidden;font-weight:500;text-overflow:ellipsis;text-decoration:none;vertical-align:top;box-sizing:border-box;font-size:14px;line-height:21px;border-radius:4px;padding:7px 14px 9px;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#fff;color:#3d4145;border-color:#ccced0}.wp-core-ui.wp-admin .wcc-root .button.hidden{display:none}.wp-core-ui.wp-admin .wcc-root .button .gridicon{position:relative;top:4px;margin-top:-2px;width:18px;height:18px}.wp-core-ui.wp-admin .wcc-root .button .gridicon:not(:last-child){margin-right:4px}.wp-core-ui.wp-admin .wcc-root .button:active,.wp-core-ui.wp-admin .wcc-root .button.is-active{border-width:2px 1px 1px}.wp-core-ui.wp-admin .wcc-root .button:hover{border-color:#b0b5b8;color:#3d4145}.wp-core-ui.wp-admin .wcc-root .button:visited{color:#3d4145}.wp-core-ui.wp-admin .wcc-root .button[disabled],.wp-core-ui.wp-admin .wcc-root .button:disabled,.wp-core-ui.wp-admin .wcc-root .button.disabled{color:#e1e2e2;background-color:#fff;border-color:#e1e2e2;cursor:default}.wp-core-ui.wp-admin .wcc-root .button[disabled]:active,.wp-core-ui.wp-admin .wcc-root .button[disabled].is-active,.wp-core-ui.wp-admin .wcc-root .button:disabled:active,.wp-core-ui.wp-admin .wcc-root .button:disabled.is-active,.wp-core-ui.wp-admin .wcc-root .button.disabled:active,.wp-core-ui.wp-admin .wcc-root .button.disabled.is-active{border-width:1px 1px 2px}.accessible-focus .wp-core-ui.wp-admin .wcc-root .button:focus{border-color:#016087;box-shadow:0 0 0 2px #6f93ad}.wp-core-ui.wp-admin .wcc-root .button.is-compact{padding:7px;color:#636d75;font-size:12px;line-height:1}.wp-core-ui.wp-admin .wcc-root .button.is-compact:disabled{color:#e1e2e2}.wp-core-ui.wp-admin .wcc-root .button.is-compact .gridicon{top:5px;margin-top:-8px}.wp-core-ui.wp-admin .wcc-root .button.is-compact .gridicons-plus-small{margin-left:-4px}.wp-core-ui.wp-admin .wcc-root .button.is-compact .gridicons-plus-small:last-of-type{margin-left:0}.wp-core-ui.wp-admin .wcc-root .button.is-compact .gridicons-plus-small+.gridicon{margin-left:-4px}.wp-core-ui.wp-admin .wcc-root .button.is-busy{animation:button__busy-animation 3000ms infinite linear;background-size:120px 100%;background-image:linear-gradient(-45deg, #f6f6f6 28%, #fff 28%, #fff 72%, #f6f6f6 72%)}.wp-core-ui.wp-admin .wcc-root .button.is-primary{background-color:#d52c82;border-color:#992053;color:#fff}.wp-core-ui.wp-admin .wcc-root .button.is-primary:hover,.wp-core-ui.wp-admin .wcc-root .button.is-primary:focus{background-color:#ff3997;border-color:#992053;color:#fff}.accessible-focus .wp-core-ui.wp-admin .wcc-root .button.is-primary:focus{box-shadow:0 0 0 2px #ff76b8}.wp-core-ui.wp-admin .wcc-root .button.is-primary.is-compact{color:#fff}.wp-core-ui.wp-admin .wcc-root .button.is-primary[disabled],.wp-core-ui.wp-admin .wcc-root .button.is-primary:disabled,.wp-core-ui.wp-admin .wcc-root .button.is-primary.disabled{color:#e1e2e2;background-color:#fff;border-color:#e1e2e2}.wp-core-ui.wp-admin .wcc-root .button.is-primary.is-busy{background-image:linear-gradient(-45deg, #d52c82 28%, #b7266a 28%, #b7266a 72%, #d52c82 72%)}.wp-core-ui.wp-admin .wcc-root .button.is-scary{color:#eb0001}.wp-core-ui.wp-admin .wcc-root .button.is-scary:hover,.wp-core-ui.wp-admin .wcc-root .button.is-scary:focus{border-color:#eb0001}.accessible-focus .wp-core-ui.wp-admin .wcc-root .button.is-scary:focus{box-shadow:0 0 0 2px #ff8248}.wp-core-ui.wp-admin .wcc-root .button.is-scary[disabled],.wp-core-ui.wp-admin .wcc-root .button.is-scary:disabled{color:#e1e2e2;background-color:#fff;border-color:#e1e2e2}.wp-core-ui.wp-admin .wcc-root .button.is-primary.is-scary{background-color:#eb0001;border-color:#ac120b;color:#fff}.wp-core-ui.wp-admin .wcc-root .button.is-primary.is-scary:hover,.wp-core-ui.wp-admin .wcc-root .button.is-primary.is-scary:focus{background-color:#ff4b1c}.wp-core-ui.wp-admin .wcc-root .button.is-primary.is-scary[disabled],.wp-core-ui.wp-admin .wcc-root .button.is-primary.is-scary:disabled{color:#e1e2e2;background-color:#fff;border-color:#e1e2e2}.wp-core-ui.wp-admin .wcc-root .button.is-primary.is-scary.is-busy{background-image:linear-gradient(-45deg, #eb0001 28%, #cb0c07 28%, #cb0c07 72%, #eb0001 72%)}.wp-core-ui.wp-admin .wcc-root .button.is-borderless{border:none;background:none;color:#636d75;padding-left:0;padding-right:0}.wp-core-ui.wp-admin .wcc-root .button.is-borderless:hover,.wp-core-ui.wp-admin .wcc-root .button.is-borderless:focus{background:none;color:#3d4145}.wp-core-ui.wp-admin .wcc-root .button.is-borderless .gridicon{width:24px;height:24px;top:6px}.wp-core-ui.wp-admin .wcc-root .button.is-borderless[disabled],.wp-core-ui.wp-admin .wcc-root .button.is-borderless:disabled{color:#e1e2e2;cursor:default}.wp-core-ui.wp-admin .wcc-root .button.is-borderless[disabled]:active,.wp-core-ui.wp-admin .wcc-root .button.is-borderless[disabled].is-active,.wp-core-ui.wp-admin .wcc-root .button.is-borderless:disabled:active,.wp-core-ui.wp-admin .wcc-root .button.is-borderless:disabled.is-active{border-width:0}.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-scary{color:#eb0001}.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-scary:hover,.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-scary:focus{color:#cb0c07}.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-scary[disabled]{color:#ffe2cd}.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-primary{color:#d52c82}.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-primary:focus,.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-primary:hover,.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-primary:active,.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-primary.is-active{color:#992053}.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-primary:focus{box-shadow:0 0 0 2px #ff76b8}.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-primary[disabled]{color:#e1e2e2}.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-compact .gridicon{width:18px;height:18px;top:5px}.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-compact .gridicons-arrow-left{top:4px;margin-right:4px}.wp-core-ui.wp-admin .wcc-root .button.is-borderless.is-compact .gridicons-arrow-right{top:4px;margin-left:4px}.wp-core-ui.wp-admin .wcc-root .layout__content input[type='reset'],.wp-core-ui.wp-admin .wcc-root .layout__content input[type='reset']:hover,.wp-core-ui.wp-admin .wcc-root .layout__content input[type='reset']:active,.wp-core-ui.wp-admin .wcc-root .layout__content input[type='reset']:focus,.wp-core-ui.wp-admin .wcc-root .dialog__content input[type='reset'],.wp-core-ui.wp-admin .wcc-root .dialog__content input[type='reset']:hover,.wp-core-ui.wp-admin .wcc-root .dialog__content input[type='reset']:active,.wp-core-ui.wp-admin .wcc-root .dialog__content input[type='reset']:focus{background:0 0;border:0;padding:0 2px 1px;width:auto;box-shadow:none}.wp-core-ui.wp-admin .wcc-root .layout__content p .button,.wp-core-ui.wp-admin .wcc-root .dialog__content p .button{vertical-align:baseline}.wp-core-ui.wp-admin .wcc-root .layout__content button::-moz-focus-inner,.wp-core-ui.wp-admin .wcc-root .layout__content input[type='reset']::-moz-focus-inner,.wp-core-ui.wp-admin .wcc-root .layout__content input[type='button']::-moz-focus-inner,.wp-core-ui.wp-admin .wcc-root .layout__content input[type='submit']::-moz-focus-inner,.wp-core-ui.wp-admin .wcc-root .dialog__content button::-moz-focus-inner,.wp-core-ui.wp-admin .wcc-root .dialog__content input[type='reset']::-moz-focus-inner,.wp-core-ui.wp-admin .wcc-root .dialog__content input[type='button']::-moz-focus-inner,.wp-core-ui.wp-admin .wcc-root .dialog__content input[type='submit']::-moz-focus-inner{border:0;padding:0}.wp-core-ui.wp-admin .wcc-root .button.is-link{background:transparent;border:none;border-radius:0;padding:0;color:#016087;font-weight:400;font-size:inherit;line-height:1.65}.wp-core-ui.wp-admin .wcc-root .button.is-link:hover,.wp-core-ui.wp-admin .wcc-root .button.is-link:focus,.wp-core-ui.wp-admin .wcc-root .button.is-link:active,.wp-core-ui.wp-admin .wcc-root .button.is-link.is-active{color:#23354b;box-shadow:none}@keyframes button__busy-animation{0%{background-position:240px 0}}.wp-core-ui.wp-admin .wcc-root .button-group .button{border-left-width:0;border-radius:0}.wp-core-ui.wp-admin .wcc-root .button-group .button:focus{position:relative;z-index:1}.wp-core-ui.wp-admin .wcc-root .button-group .button:first-child{border-left-width:1px;border-top-left-radius:4px;border-bottom-left-radius:4px}.wp-core-ui.wp-admin .wcc-root .button-group .button:first-child:active{border-right-width:0}.wp-core-ui.wp-admin .wcc-root .button-group .button:last-child{border-top-right-radius:4px;border-bottom-right-radius:4px}.wp-core-ui.wp-admin .wcc-root .button-group .button:last-child:active{border-left-width:0}.section-header .wp-core-ui.wp-admin .wcc-root .button-group .button{margin-right:0}.wp-core-ui.wp-admin .wcc-root .button-group.is-primary.is-busy{background-size:120px 100%;background-image:linear-gradient(-45deg, #d52c82 28%, #b7266a 28%, #b7266a 72%, #d52c82 72%)}.wp-core-ui.wp-admin .wcc-root .button-group.is-busy{animation:button__busy-animation 3000ms infinite linear;background-size:120px 100%;background-image:linear-gradient(-45deg, #f6f6f6 28%, #fff 28%, #fff 72%, #f6f6f6 72%);display:inline-block;border-radius:4px}.wp-core-ui.wp-admin .wcc-root .button-group.is-busy .button{background-color:transparent}@keyframes button__busy-animation{0%{background-position:240px 0}}.wp-core-ui.wp-admin .wcc-root .card{display:block;position:relative;margin:0 auto 10px;padding:16px;box-sizing:border-box;background:#fff;box-shadow:0 0 0 1px #e1e2e2}.wp-core-ui.wp-admin .wcc-root .card::after{content:'.';display:block;height:0;width:0;clear:both;visibility:hidden;overflow:hidden}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .card{margin-bottom:16px;padding:24px}}.wp-core-ui.wp-admin .wcc-root .card.is-compact{margin-bottom:1px}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .card.is-compact{margin-bottom:1px;padding:16px 24px}}.wp-core-ui.wp-admin .wcc-root .card.is-card-link{padding-right:48px}.wp-core-ui.wp-admin .wcc-root .card.is-card-link:not(a){color:#016087;font-size:100%;line-height:1.5;text-align:left;width:100%}.wp-core-ui.wp-admin .wcc-root .card.is-card-link:not(a):active,.wp-core-ui.wp-admin .wcc-root .card.is-card-link:not(a):focus,.wp-core-ui.wp-admin .wcc-root .card.is-card-link:not(a):hover{color:#23354b}.wp-core-ui.wp-admin .wcc-root .card.is-clickable{cursor:pointer}.wp-core-ui.wp-admin .wcc-root .card.is-highlight{padding-left:21px}.wp-core-ui.wp-admin .wcc-root .card.is-error{border-left:3px solid #eb0001}.wp-core-ui.wp-admin .wcc-root .card.is-info{border-left:3px solid #016087}.wp-core-ui.wp-admin .wcc-root .card.is-success{border-left:3px solid #008a00}.wp-core-ui.wp-admin .wcc-root .card.is-warning{border-left:3px solid #f6c200}.wp-core-ui.wp-admin .wcc-root .card__link-indicator{color:#636d75;display:block;height:100%;position:absolute;top:0;right:16px}html[dir='rtl'] .wp-core-ui.wp-admin .wcc-root .card__link-indicator.gridicons-chevron-right{transform:scaleX(-1)}.wp-core-ui.wp-admin .wcc-root a.card:hover .card__link-indicator,.wp-core-ui.wp-admin .wcc-root .is-card-link.card:hover .card__link-indicator{color:#2b2d2f}.wp-core-ui.wp-admin .wcc-root a.card:focus,.wp-core-ui.wp-admin .wcc-root .is-card-link.card:focus{outline:0}.wp-core-ui.wp-admin .wcc-root a.card:focus .card__link-indicator,.wp-core-ui.wp-admin .wcc-root .is-card-link.card:focus .card__link-indicator{color:#23354b}.wp-core-ui.wp-admin .wcc-root .dialog__backdrop{align-items:center;bottom:0;left:0;display:flex;justify-content:center;position:fixed;right:0;top:46px;transition:background-color 0.2s ease-in;z-index:100200}.wp-core-ui.wp-admin .wcc-root .dialog__backdrop.dialog-enter,.wp-core-ui.wp-admin .wcc-root .dialog__backdrop.dialog-leave.dialog-leave-active{background-color:rgba(246,246,246, 0)}.wp-core-ui.wp-admin .wcc-root .dialog__backdrop,.wp-core-ui.wp-admin .wcc-root .dialog__backdrop.dialog-enter.dialog-enter-active,.wp-core-ui.wp-admin .wcc-root .dialog__backdrop.dialog-leave{background-color:rgba(246,246,246, 0.8)}.wp-core-ui.wp-admin .wcc-root .dialog__backdrop.is-full-screen{top:0}.wp-core-ui.wp-admin .wcc-root .dialog__backdrop.is-hidden{background-color:transparent}.wp-core-ui.wp-admin .wcc-root .dialog.card{position:relative;display:flex;flex-direction:column;max-width:90%;max-height:90%;margin:auto 0;padding:0;opacity:1;transition:opacity 0.2s ease-in}.dialog-enter .wp-core-ui.wp-admin .wcc-root .dialog.card,.dialog-leave.dialog-leave-active .wp-core-ui.wp-admin .wcc-root .dialog.card{opacity:0}.wp-core-ui.wp-admin .wcc-root .dialog.card,.dialog-enter.dialog-enter-active .wp-core-ui.wp-admin .wcc-root .dialog.card,.dialog-leave .wp-core-ui.wp-admin .wcc-root .dialog.card{opacity:1}.wp-core-ui.wp-admin .wcc-root .dialog__content{padding:16px;overflow-y:auto}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .dialog__content{padding:24px}}.wp-core-ui.wp-admin .wcc-root .dialog__content:last-child{bottom:0}.wp-core-ui.wp-admin .wcc-root .dialog__content h1{color:#3d4145;font-size:1.375em;font-weight:600;line-height:2em;margin-bottom:0.5em}.wp-core-ui.wp-admin .wcc-root .dialog__content p:last-child{margin-bottom:0}.wp-core-ui.wp-admin .wcc-root .dialog__action-buttons{position:relative;border-top:1px solid #f6f6f6;padding:16px;margin:0;text-align:right;flex-shrink:0;background-color:#fff}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .dialog__action-buttons{padding-left:24px;padding-right:24px}}@media (max-width: 480px){.wp-core-ui.wp-admin .wcc-root .dialog__action-buttons{display:flex;flex-direction:column-reverse}}.wp-core-ui.wp-admin .wcc-root .dialog__action-buttons::before{content:'';display:block;position:absolute;bottom:100%;left:16px;right:16px;height:24px;background:linear-gradient(to bottom, rgba(255,255,255,0) 0%, #fff 100%);margin-bottom:1px}.wp-core-ui.wp-admin .wcc-root .dialog__action-buttons .button{margin-left:10px;min-width:80px;text-align:center}.wp-core-ui.wp-admin .wcc-root .dialog__action-buttons .button .is-left-aligned{margin-left:0;margin-right:10px}@media (max-width: 480px){.wp-core-ui.wp-admin .wcc-root .dialog__action-buttons .button{margin:2px 0}}.wp-core-ui.wp-admin .wcc-root .dialog__action-buttons .is-left-aligned{float:left}.wp-core-ui.wp-admin .wcc-root .ReactModal__Body--open{overflow:hidden}.wp-core-ui.wp-admin .wcc-root .ReactModal__Html--open{overflow:visible}.wp-core-ui.wp-admin .wcc-root .gridicon.ellipsis-menu__toggle-icon{transition:transform 0.15s cubic-bezier(0.175, 0.885, 0.32, 1.275)}.wp-core-ui.wp-admin .wcc-root .ellipsis-menu.is-menu-visible .gridicon.ellipsis-menu__toggle-icon{transform:rotate(90deg)}.wp-core-ui.wp-admin .wcc-root .external-link .gridicons-external{color:currentColor;margin-left:3px;margin-right:0;top:2px;position:relative}.wp-core-ui.wp-admin .wcc-root .external-link:hover{cursor:pointer}.wp-core-ui.wp-admin .wcc-root .icon-first .gridicons-external{margin-left:0;margin-right:3px}.wp-core-ui.wp-admin .wcc-root .foldable-card.card{position:relative;transition:margin 0.15s linear;padding:0}.wp-core-ui.wp-admin .wcc-root .foldable-card.card::after{content:'.';display:block;height:0;width:0;clear:both;visibility:hidden;overflow:hidden}.wp-core-ui.wp-admin .wcc-root .foldable-card.card.is-expanded{margin:8px 0}.wp-core-ui.wp-admin .wcc-root .foldable-card__header{min-height:64px;width:100%;padding:16px;box-sizing:border-box;display:flex;align-items:center;justify-content:space-between;position:relative}.wp-core-ui.wp-admin .wcc-root .foldable-card__header.is-clickable{cursor:pointer}.wp-core-ui.wp-admin .wcc-root .foldable-card__header.has-border .foldable-card__summary,.wp-core-ui.wp-admin .wcc-root .foldable-card__header.has-border .foldable-card__summary-expanded{margin-right:48px}.wp-core-ui.wp-admin .wcc-root .foldable-card__header.has-border .foldable-card__expand{border-left:1px #f6f6f6 solid}.wp-core-ui.wp-admin .wcc-root .foldable-card.is-compact .foldable-card__header{padding:8px 16px;min-height:40px}.wp-core-ui.wp-admin .wcc-root .foldable-card.is-expanded .foldable-card__header{margin-bottom:0;height:inherit;min-height:64px}.wp-core-ui.wp-admin .wcc-root .foldable-card.is-expanded.is-compact .foldable-card__header{min-height:40px}.wp-core-ui.wp-admin .wcc-root .foldable-card.is-disabled .foldable-card__header{opacity:0.2}.wp-core-ui.wp-admin .wcc-root .foldable-card__action{position:absolute;top:0;right:0;height:100%}.wp-core-ui.wp-admin .wcc-root .foldable-card.is-expanded .foldable-card__action{height:100%}.wp-core-ui.wp-admin .wcc-root .foldable-card.is-disabled .foldable-card__action{cursor:default}.wp-core-ui.wp-admin .wcc-root .accessible-focus .foldable-card__action:focus{outline:thin dotted}.wp-core-ui.wp-admin .wcc-root button.foldable-card__action{cursor:pointer}.wp-core-ui.wp-admin .wcc-root .foldable-card__main{max-width:calc( 100% - 36px);display:flex;align-items:center;flex:2 1;margin-right:5px}@media (max-width: 480px){.wp-core-ui.wp-admin .wcc-root .foldable-card__main{flex:1 1}}.wp-core-ui.wp-admin .wcc-root .foldable-card__secondary{display:flex;align-items:center;flex:1 1;justify-content:flex-end}@media (max-width: 480px){.wp-core-ui.wp-admin .wcc-root .foldable-card__secondary{flex:0 1}}.wp-core-ui.wp-admin .wcc-root .foldable-card__expand{width:48px}.wp-core-ui.wp-admin .wcc-root .foldable-card__expand .gridicon{fill:#969ca1;display:flex;align-items:center;width:100%;vertical-align:middle;transition:transform 0.15s cubic-bezier(0.175, 0.885, 0.32, 1.275),color 0.2s ease-in}.wp-core-ui.wp-admin .wcc-root .foldable-card__expand .gridicon:hover{fill:#969ca1}.wp-core-ui.wp-admin .wcc-root .foldable-card__expand:hover .gridicon{fill:#636d75}.wp-core-ui.wp-admin .wcc-root .foldable-card.is-expanded .foldable-card__expand .gridicon{transform:rotate(180deg)}.wp-core-ui.wp-admin .wcc-root .foldable-card__content{display:none}.wp-core-ui.wp-admin .wcc-root .foldable-card.is-expanded .foldable-card__content{display:block;padding:16px;border-top:1px solid #f6f6f6}.wp-core-ui.wp-admin .wcc-root .foldable-card.is-compact .foldable-card.is-expanded .foldable-card__content{padding:8px}.wp-core-ui.wp-admin .wcc-root .foldable-card__summary,.wp-core-ui.wp-admin .wcc-root .foldable-card__summary-expanded{margin-right:40px;color:#636d75;font-size:12px;transition:opacity 0.2s linear;display:inline-block}@media (max-width: 480px){.wp-core-ui.wp-admin .wcc-root .foldable-card__summary,.wp-core-ui.wp-admin .wcc-root .foldable-card__summary-expanded{display:none}}.wp-core-ui.wp-admin .wcc-root .foldable-card.has-expanded-summary .foldable-card__summary,.wp-core-ui.wp-admin .wcc-root .foldable-card.has-expanded-summary .foldable-card__summary-expanded{transition:none;flex:2;text-align:right}.wp-core-ui.wp-admin .wcc-root .foldable-card__summary{opacity:1;display:inline-block}.wp-core-ui.wp-admin .wcc-root .foldable-card.is-expanded .foldable-card__summary{display:none}.wp-core-ui.wp-admin .wcc-root .has-expanded-summary .foldable-card.is-expanded .foldable-card__summary{display:none}.wp-core-ui.wp-admin .wcc-root .foldable-card__summary-expanded{display:none}.wp-core-ui.wp-admin .wcc-root .foldable-card.is-expanded .foldable-card__summary-expanded{display:inline-block}.wp-core-ui.wp-admin .wcc-root .form-button{float:right;margin-left:10px}.wp-core-ui.wp-admin .wcc-root .form-currency-input{-webkit-appearance:none}.wp-core-ui.wp-admin .wcc-root .form-currency-input__affix{display:flex;align-items:center}.wp-core-ui.wp-admin .wcc-root .form-currency-input__select-icon{color:#969ca1;margin-left:6px;-ms-grid-row-align:center;align-self:center}.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__prefix:hover .form-currency-input__select-icon,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__suffix:hover .form-currency-input__select-icon{color:#636d75}.wp-core-ui.wp-admin .wcc-root .form-currency-input__select{position:absolute;top:0;bottom:0;left:0;right:0;width:100%;padding:0;border:0;background-image:none;opacity:0}.wp-core-ui.wp-admin .wcc-root .form-fieldset{clear:both;margin-bottom:20px}.wp-core-ui.wp-admin .wcc-root .form-input-validation{color:#008a00;position:relative;padding:6px 24px 11px 34px;border-radius:1px;box-sizing:border-box;font-size:14px;animation:appear 0.3s ease-in-out}.wp-core-ui.wp-admin .wcc-root .form-input-validation.is-error{color:#eb0001}.wp-core-ui.wp-admin .wcc-root .form-input-validation.is-warning{color:#f6c200}.wp-core-ui.wp-admin .wcc-root .form-input-validation.is-hidden{animation:none;visibility:hidden}.wp-core-ui.wp-admin .wcc-root .form-input-validation .gridicon{float:left;margin-left:-34px}.wp-core-ui.wp-admin .wcc-root .form-label{display:block;font-size:14px;font-weight:600;margin-bottom:5px}.wp-core-ui.wp-admin .wcc-root .form-label .form-label__required{color:#eb0001;font-weight:normal;margin-left:6px}.wp-core-ui.wp-admin .wcc-root .form-label .form-label__optional{color:#636d75;font-weight:normal;margin-left:6px}.wp-core-ui.wp-admin .wcc-root .form-label input[type='checkbox']+span,.wp-core-ui.wp-admin .wcc-root .form-label input[type='radio']+span{font-weight:normal}.wp-core-ui.wp-admin .wcc-root .form-legend{font-size:14px;font-weight:600;margin-bottom:5px}.wp-core-ui.wp-admin .wcc-root li .form-legend{margin-top:4px}.wp-core-ui.wp-admin .wcc-root .form-section-heading{font-size:24px;font-weight:300;margin:30px 0 20px}.wp-core-ui.wp-admin .wcc-root .form-section-heading:first-child{margin-top:0}.wp-core-ui.wp-admin .wcc-root .form-select{margin-bottom:1em}.wp-core-ui.wp-admin .wcc-root .form-select.is-error{border-color:#eb0001}.wp-core-ui.wp-admin .wcc-root .form-select.is-error:hover{border-color:#ac120b}.wp-core-ui.wp-admin .wcc-root .form-select:disabled{color:#ccced0}.wp-core-ui.wp-admin .wcc-root .form-select:focus.is-error{box-shadow:0 0 0 2px #ffcfac}.wp-core-ui.wp-admin .wcc-root .form-select:focus.is-error:hover{box-shadow:0 0 0 2px #ffab78}.wp-core-ui.wp-admin .wcc-root .form-select:only-of-type,.wp-core-ui.wp-admin .wcc-root .form-select:last-of-type{margin-bottom:0}.wp-core-ui.wp-admin .wcc-root .form-setting-explanation{color:#636d75;display:block;font-size:13px;font-style:italic;font-weight:400;margin:5px 0 0}.wp-core-ui.wp-admin .wcc-root .form-setting-explanation.is-indented{margin-left:24px}.wp-core-ui.wp-admin .wcc-root .form-setting-explanation button.is-borderless{color:#016087;font-size:inherit;font-style:inherit;font-weight:inherit;line-height:inherit;padding:0}.wp-core-ui.wp-admin .wcc-root .form-setting-explanation button.is-borderless:hover{color:#23354b}.wp-core-ui.wp-admin .wcc-root input[type='email'].form-text-input,.wp-core-ui.wp-admin .wcc-root input[type='password'].form-text-input,.wp-core-ui.wp-admin .wcc-root input[type='url'].form-text-input,.wp-core-ui.wp-admin .wcc-root input[type='text'].form-text-input{-webkit-appearance:none}.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes{display:inline-flex;flex-direction:column;width:100%}.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes.no-wrap{flex-direction:row}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes{flex-direction:row}}.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='email'],.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='password'],.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='url'],.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='text'],.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='number']{flex-grow:1}.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='email']:focus,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='password']:focus,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='url']:focus,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='text']:focus,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='number']:focus{transform:scale(1)}.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='email']:disabled,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='password']:disabled,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='url']:disabled,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='text']:disabled,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='number']:disabled{border-right-width:0}.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='email']:disabled+.form-text-input-with-affixes__suffix,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='password']:disabled+.form-text-input-with-affixes__suffix,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='url']:disabled+.form-text-input-with-affixes__suffix,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='text']:disabled+.form-text-input-with-affixes__suffix,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes input[type='number']:disabled+.form-text-input-with-affixes__suffix{border-left:1px solid #ccced0}.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__prefix,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__suffix{position:relative;background:transparent;border:1px solid #ccced0;color:#636d75;padding:8px 14px;white-space:nowrap;flex:1 0 auto;font-size:16px;line-height:1.5}.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__prefix{border-top-left-radius:2px;border-top-right-radius:2px}@media (max-width: 480px){:not(.no-wrap)>.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__prefix{border-bottom:none}}.no-wrap>.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__prefix{border-bottom-left-radius:2px;border-right:none;border-top-right-radius:0}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__prefix{border-bottom-left-radius:2px;border-right:none;border-top-right-radius:0}}.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__prefix+input[type='email']:disabled,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__prefix+input[type='password']:disabled,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__prefix+input[type='url']:disabled,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__prefix+input[type='text']:disabled,.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__prefix+input[type='number']:disabled{border-left-color:#ccced0;border-right-width:1px}.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__suffix{border-bottom-left-radius:2px;border-bottom-right-radius:2px}@media (max-width: 480px){:not(.no-wrap)>.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__suffix{border-top:none}}.no-wrap>.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__suffix{border-bottom-left-radius:0;border-left:none;border-top-right-radius:2px}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .form-text-input-with-affixes__suffix{border-bottom-left-radius:0;border-left:none;border-top-right-radius:2px}}.wp-core-ui.wp-admin .wcc-root .form-toggle[type='checkbox']{display:none}.wp-core-ui.wp-admin .wcc-root .form-toggle__switch{position:relative;display:inline-block;border-radius:12px;box-sizing:border-box;padding:2px;width:40px;height:24px;vertical-align:middle;align-self:flex-start;outline:0;cursor:pointer;transition:all 0.4s ease, box-shadow 0s}.wp-core-ui.wp-admin .wcc-root .form-toggle__switch::before,.wp-core-ui.wp-admin .wcc-root .form-toggle__switch::after{position:relative;display:block;content:'';width:20px;height:20px}.wp-core-ui.wp-admin .wcc-root .form-toggle__switch::after{left:0;border-radius:50%;background:#fff;transition:all 0.2s ease}.wp-core-ui.wp-admin .wcc-root .form-toggle__switch::before{display:none}.accessible-focus .wp-core-ui.wp-admin .wcc-root .form-toggle__switch:focus{box-shadow:0 0 0 2px #016087}.wp-core-ui.wp-admin .wcc-root .form-toggle__label{cursor:pointer}.is-disabled .wp-core-ui.wp-admin .wcc-root .form-toggle__label{cursor:default}.wp-core-ui.wp-admin .wcc-root .form-toggle__label .form-toggle__label-content{flex:0 1 100%;margin-left:12px}.accessible-focus .wp-core-ui.wp-admin .wcc-root .form-toggle:focus+.form-toggle__label .form-toggle__switch{box-shadow:0 0 0 2px #016087}.accessible-focus .wp-core-ui.wp-admin .wcc-root .form-toggle:focus:checked+.form-toggle__label .form-toggle__switch{box-shadow:0 0 0 2px #6f93ad}.wp-core-ui.wp-admin .wcc-root .form-toggle+.form-toggle__label .form-toggle__switch{background:#b0b5b8}.wp-core-ui.wp-admin .wcc-root .form-toggle:not(:disabled)+.form-toggle__label:hover .form-toggle__switch{background:#ccced0}.wp-core-ui.wp-admin .wcc-root .form-toggle:checked+.form-toggle__label .form-toggle__switch{background:#016087}.wp-core-ui.wp-admin .wcc-root .form-toggle:checked+.form-toggle__label .form-toggle__switch::after{left:16px}.wp-core-ui.wp-admin .wcc-root .form-toggle:checked:not(:disabled)+.form-toggle__label:hover .form-toggle__switch{background:#6f93ad}.wp-core-ui.wp-admin .wcc-root .form-toggle:disabled+label.form-toggle__label span.form-toggle__switch{opacity:0.25;cursor:default}.wp-core-ui.wp-admin .wcc-root .form-toggle.is-toggling+.form-toggle__label .form-toggle__switch{background:#016087}.wp-core-ui.wp-admin .wcc-root .form-toggle.is-toggling:checked+.form-toggle__label .form-toggle__switch{background:#ccced0}.wp-core-ui.wp-admin .wcc-root .form-toggle.is-compact+.form-toggle__label .form-toggle__switch{border-radius:8px;width:24px;height:16px}.wp-core-ui.wp-admin .wcc-root .form-toggle.is-compact+.form-toggle__label .form-toggle__switch::before,.wp-core-ui.wp-admin .wcc-root .form-toggle.is-compact+.form-toggle__label .form-toggle__switch::after{width:12px;height:12px}.wp-core-ui.wp-admin .wcc-root .form-toggle.is-compact:checked+.form-toggle__label .form-toggle__switch::after{left:8px}.wp-core-ui.wp-admin .wcc-root .global-notices{text-align:right;pointer-events:none;z-index:179;position:fixed;top:auto;right:0;bottom:0;left:0}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .global-notices{top:63px;right:16px;bottom:auto;left:auto;max-width:calc( 100% - 32px)}}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .global-notices{top:71px;right:24px;max-width:calc( 100% - 48px)}}@media (min-width: 1041px){.wp-core-ui.wp-admin .wcc-root .global-notices{right:32px;max-width:calc( 100% - 64px)}}.wp-core-ui.wp-admin .wcc-root .global-notices .notice{flex-wrap:nowrap;margin-bottom:0;text-align:left;pointer-events:auto;border-radius:0;box-shadow:0 2px 5px rgba(0,0,0,0.2),0 0 56px rgba(0,0,0,0.15)}.wp-core-ui.wp-admin .wcc-root .global-notices .notice .notice__icon-wrapper{border-radius:0}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .global-notices .notice{display:flex;overflow:hidden;margin-bottom:24px;border-radius:3px}.wp-core-ui.wp-admin .wcc-root .global-notices .notice .notice__icon-wrapper{border-radius:3px 0 0 3px}}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .global-notices .notice a.notice__action{font-size:14px;padding:13px 16px}}.wp-core-ui.wp-admin .wcc-root .global-notices .notice__dismiss{flex-shrink:0}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .global-notices .notice__dismiss{padding:13px 16px 0}}.wp-core-ui.wp-admin .wcc-root .image.is-error{display:none}.wp-core-ui.wp-admin .wcc-root .info-popover .gridicon{cursor:pointer;color:#b0b5b8}.wp-core-ui.wp-admin .wcc-root .info-popover .gridicon:hover{color:#3d4145}.wp-core-ui.wp-admin .wcc-root .info-popover.is_active .gridicon{color:#3d4145}.wp-core-ui.wp-admin .wcc-root .popover.info-popover__tooltip .popover__inner{color:#636d75;font-size:13px;max-width:220px;padding:16px;text-align:left}@keyframes notice-loading-pulse{0%{opacity:0}50%{opacity:0.5}100%{opacity:0}}.wp-core-ui.wp-admin .wcc-root .notice{display:flex;position:relative;width:100%;margin-bottom:24px;box-sizing:border-box;animation:appear 0.3s ease-in-out;background:#3d4145;color:#fff;border-radius:3px;line-height:1.5}.wp-core-ui.wp-admin .wcc-root .notice.is-success .notice__icon-wrapper{background:#008a00}.wp-core-ui.wp-admin .wcc-root .notice.is-warning .notice__icon-wrapper{background:#f6c200}.wp-core-ui.wp-admin .wcc-root .notice.is-error .notice__icon-wrapper{background:#eb0001}.wp-core-ui.wp-admin .wcc-root .notice.is-info .notice__icon-wrapper{background:#d52c82}.wp-core-ui.wp-admin .wcc-root .notice.is-loading .notice__icon-wrapper::after{content:'';background-color:#fff;animation:notice-loading-pulse 0.8s ease-in-out infinite;position:absolute;top:0;bottom:0;left:0;right:0}.wp-core-ui.wp-admin .wcc-root .notice .notice__dismiss{overflow:hidden}.wp-core-ui.wp-admin .wcc-root .notice.is-success .notice__dismiss,.wp-core-ui.wp-admin .wcc-root .notice.is-error .notice__dismiss,.wp-core-ui.wp-admin .wcc-root .notice.is-warning .notice__dismiss,.wp-core-ui.wp-admin .wcc-root .notice.is-info .notice__dismiss{overflow:hidden}.wp-core-ui.wp-admin .wcc-root .notice__icon-wrapper{position:relative;background:#636d75;color:#fff;display:flex;align-items:baseline;width:47px;justify-content:center;border-radius:3px 0 0 3px;flex-shrink:0;align-self:stretch}.wp-core-ui.wp-admin .wcc-root .notice__icon-wrapper .gridicon{margin-top:10px}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .notice__icon-wrapper .gridicon{margin-top:12px}}.wp-core-ui.wp-admin .wcc-root .notice__content{padding:13px;font-size:12px;flex-grow:1}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .notice__content{font-size:14px}}.wp-core-ui.wp-admin .wcc-root .notice__text a,.wp-core-ui.wp-admin .wcc-root .notice__text a:visited,.wp-core-ui.wp-admin .wcc-root .notice__text button.is-link{text-decoration:underline;color:#fff}.wp-core-ui.wp-admin .wcc-root .notice__text a:hover,.wp-core-ui.wp-admin .wcc-root .notice__text a:visited:hover,.wp-core-ui.wp-admin .wcc-root .notice__text button.is-link:hover{color:#fff;text-decoration:none}.wp-core-ui.wp-admin .wcc-root .notice__text ul{margin-bottom:0;margin-left:0}.wp-core-ui.wp-admin .wcc-root .notice__text li{margin-left:2em;margin-top:0.5em}.wp-core-ui.wp-admin .wcc-root .notice__text p{margin-bottom:0;margin-top:0.5em}.wp-core-ui.wp-admin .wcc-root .notice__text p:first-child{margin-top:0}.wp-core-ui.wp-admin .wcc-root .notice__button{cursor:pointer;margin-left:0.428em}.wp-core-ui.wp-admin .wcc-root .notice__dismiss{flex-shrink:0;padding:12px;cursor:pointer;padding-bottom:0}.wp-core-ui.wp-admin .wcc-root .notice__dismiss .gridicon{width:18px;height:18px}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .notice__dismiss{padding:11px;padding-bottom:0}.wp-core-ui.wp-admin .wcc-root .notice__dismiss .gridicon{width:24px;height:24px}}.notice .wp-core-ui.wp-admin .wcc-root .notice__dismiss{color:#b0b5b8}.notice .wp-core-ui.wp-admin .wcc-root .notice__dismiss:hover,.notice .wp-core-ui.wp-admin .wcc-root .notice__dismiss:focus{color:#fff}.wp-core-ui.wp-admin .wcc-root a.notice__action{cursor:pointer;font-size:12px;font-weight:400;text-decoration:none;white-space:nowrap;color:#b0b5b8;padding:13px;display:flex;align-items:center}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root a.notice__action{flex-shrink:1;flex-grow:0;align-items:center;border-radius:0;font-size:14px;margin:0 0 0 auto;padding:13px 16px}.wp-core-ui.wp-admin .wcc-root a.notice__action .gridicon{width:24px;height:24px}}.wp-core-ui.wp-admin .wcc-root a.notice__action:visited{color:#b0b5b8}.wp-core-ui.wp-admin .wcc-root a.notice__action:hover{color:#fff}.wp-core-ui.wp-admin .wcc-root a.notice__action .gridicon{margin-left:8px;opacity:0.7;width:18px;height:18px}.wp-core-ui.wp-admin .wcc-root .notice.is-compact{display:inline-flex;flex-wrap:nowrap;flex-direction:row;width:auto;border-radius:3px;min-height:20px;margin:0;padding:0;text-decoration:none;text-transform:none;vertical-align:middle;line-height:1.5}.wp-core-ui.wp-admin .wcc-root .notice.is-compact .notice__content{font-size:12px;padding:6px 10px}.wp-core-ui.wp-admin .wcc-root .notice.is-compact .notice__icon-wrapper{width:28px}.wp-core-ui.wp-admin .wcc-root .notice.is-compact .notice__icon-wrapper .notice__icon{width:18px;height:18px;margin:0}.wp-core-ui.wp-admin .wcc-root .notice.is-compact .notice__icon-wrapper .gridicon{margin-top:6px}.wp-core-ui.wp-admin .wcc-root .notice.is-compact .notice__dismiss{position:relative;-ms-grid-row-align:center;align-self:center;flex:none;margin:0 8px 0 0;padding:0}.wp-core-ui.wp-admin .wcc-root .notice.is-compact .notice__dismiss .gridicon{width:18px;height:18px}.wp-core-ui.wp-admin .wcc-root .notice.is-compact a.notice__action{background:transparent;display:inline-block;margin:0;font-size:12px;-ms-grid-row-align:center;align-self:center;margin-left:16px;padding:0 10px}.wp-core-ui.wp-admin .wcc-root .notice.is-compact a.notice__action:hover,.wp-core-ui.wp-admin .wcc-root .notice.is-compact a.notice__action:active,.wp-core-ui.wp-admin .wcc-root .notice.is-compact a.notice__action:focus{background:transparent}.wp-core-ui.wp-admin .wcc-root .notice.is-compact a.notice__action .gridicon{margin-left:8px;width:14px;height:14px;vertical-align:sub;opacity:1}.wp-core-ui.wp-admin .wcc-root .payment-logo{background-position:0 center;background-repeat:no-repeat;background-size:35px auto;display:inline-block;height:20px;vertical-align:middle;width:35px}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-amex{background-image:url("https://wordpress.com//calypso/images/upgrades/cc-amex.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-diners{background-image:url("https://wordpress.com//calypso/images/upgrades/cc-diners.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-discover{background-image:url("https://wordpress.com//calypso/images/upgrades/cc-discover.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-jcb{background-image:url("https://wordpress.com//calypso/images/upgrades/cc-jcb.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-mastercard{background-image:url("https://wordpress.com//calypso/images/upgrades/cc-mastercard.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-unionpay{background-image:url("https://wordpress.com//calypso/images/upgrades/cc-unionpay.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-visa{background-image:url("https://wordpress.com//calypso/images/upgrades/cc-visa.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-alipay{background-image:url("https://wordpress.com//calypso/images/upgrades/alipay.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-bancontact{background-image:url("https://wordpress.com//calypso/images/upgrades/bancontact.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-giropay{background-image:url("https://wordpress.com//calypso/images/upgrades/giropay.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-eps{background-image:url("https://wordpress.com//calypso/images/upgrades/eps.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-ideal{background-image:url("https://wordpress.com//calypso/images/upgrades/ideal.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-paypal{background-image:url("https://wordpress.com//calypso/images/upgrades/paypal.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-p24{background-image:url("https://wordpress.com//calypso/images/upgrades/p24.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-brazil-tef{background-image:url("https://wordpress.com//calypso/images/upgrades/brazil-tef.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-wechat{background-image:url("https://wordpress.com//calypso/images/upgrades/wechat.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-sofort{background-image:url("https://wordpress.com//calypso/images/upgrades/sofort.svg")}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-paypal{background-size:70px;width:70px}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-paypal.is-compact{width:16px}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-ideal{height:30px}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-giropay{background-size:60px auto;width:60px;height:20px}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-bancontact{height:20px;background-size:100px auto;width:100px}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-p24{height:20px;background-size:70px auto;width:70px}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-alipay{height:20px;background-size:70px auto;width:70px}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-brazil-tef{background-size:100px auto;width:100px}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-sofort{background-size:60px auto;width:80px;height:20px}.wp-core-ui.wp-admin .wcc-root .payment-logo.is-sofort.is-compact{width:16px}.wp-core-ui.wp-admin .wcc-root .screen-reader-text{clip:rect(1px, 1px, 1px, 1px);position:absolute !important}.wp-core-ui.wp-admin .wcc-root .screen-reader-text:hover,.wp-core-ui.wp-admin .wcc-root .screen-reader-text:active,.wp-core-ui.wp-admin .wcc-root .screen-reader-text:focus{background-color:#f1f1f1;border-radius:3px;box-shadow:0 0 2px 2px rgba(0,0,0,0.6);clip:auto !important;color:#21759b;display:block;font-size:14px;font-weight:bold;height:auto;left:5px;line-height:normal;padding:15px 23px 14px;text-decoration:none;top:5px;width:auto;z-index:100000}.wp-core-ui.wp-admin .wcc-root .segmented-control{display:flex;margin:0;border-radius:4px;background-color:#fff;list-style:none}.wp-core-ui.wp-admin .wcc-root .segmented-control__item{flex:1 1 auto;cursor:pointer}.wp-core-ui.wp-admin .wcc-root .segmented-control__item:first-of-type .segmented-control__link{border-top-left-radius:4px;border-bottom-left-radius:4px}.wp-core-ui.wp-admin .wcc-root .segmented-control__item:last-of-type .segmented-control__link{border-right:solid 1px #ccced0;border-top-right-radius:4px;border-bottom-right-radius:4px}.wp-core-ui.wp-admin .wcc-root .segmented-control__item.is-selected+.segmented-control__item .segmented-control__link{border-left-color:#3d4145}.wp-core-ui.wp-admin .wcc-root .segmented-control__link{display:block;padding:8px 12px;border:solid 1px #ccced0;border-right:none;font-size:14px;line-height:18px;color:#636d75;text-align:center;transition:color 0.1s linear, background-color 0.1s linear}.wp-core-ui.wp-admin .wcc-root .segmented-control__link:focus{color:#3d4145;outline:none;background-color:#f6f6f6}.wp-core-ui.wp-admin .wcc-root .segmented-control__item.is-selected .segmented-control__link{border-color:#3d4145;color:#3d4145}.wp-core-ui.wp-admin .wcc-root .notouch .segmented-control__link:hover{color:#3d4145;background-color:#f6f6f6}.wp-core-ui.wp-admin .wcc-root .segmented-control__text{display:block;max-width:100%;color:inherit;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.wp-core-ui.wp-admin .wcc-root .segmented-control.is-compact .segmented-control__link{font-size:13px;padding:4px 8px}.wp-core-ui.wp-admin .wcc-root .segmented-control.is-primary .segmented-control__item.is-selected .segmented-control__link{border-color:#016087;background-color:#016087;color:#fff}.wp-core-ui.wp-admin .wcc-root .segmented-control.is-primary .segmented-control__item.is-selected .segmented-control__link:focus{background-color:#6f93ad}.wp-core-ui.wp-admin .wcc-root .segmented-control.is-primary .segmented-control__item.is-selected+.segmented-control__item .segmented-control__link{border-left-color:#016087}.wp-core-ui.wp-admin .wcc-root .segmented-control.is-primary .segmented-control__link:focus{background-color:#f6f6f6}.wp-core-ui.wp-admin .wcc-root .notouch .segmented-control.is-primary .segmented-control__link:hover{background-color:#f6f6f6}.wp-core-ui.wp-admin .wcc-root .notouch .segmented-control.is-primary .segmented-control__item.is-selected .segmented-control__link:hover{background-color:#6f93ad}@keyframes rotate-spinner{100%{transform:rotate(360deg)}}.wp-core-ui.wp-admin .wcc-root .spinner{display:flex;align-items:center}.wp-core-ui.wp-admin .wcc-root .spinner__outer,.wp-core-ui.wp-admin .wcc-root .spinner__inner{margin:auto;box-sizing:border-box;border:0.1em solid transparent;border-radius:50%;animation:3s linear infinite;animation-name:rotate-spinner}.wp-core-ui.wp-admin .wcc-root .spinner__outer{border-top-color:#d52c82}.wp-core-ui.wp-admin .wcc-root .spinner__inner{width:100%;height:100%;border-top-color:#d52c82;border-right-color:#d52c82;opacity:0.4}.wp-core-ui.wp-admin .wcc-root.woocommerce .bulk-select{display:inline-block}.wp-core-ui.wp-admin .wcc-root.woocommerce .bulk-select__container{cursor:pointer;display:flex;align-items:center;position:relative}.wp-core-ui.wp-admin .wcc-root.woocommerce .bulk-select__container .gridicon{color:#016087;height:16px;position:absolute;left:0;top:0;width:16px}.wp-core-ui.wp-admin .wcc-root.woocommerce .bulk-select__container .gridicon.is-disabled{color:#969ca1}.wp-core-ui.wp-admin .wcc-root.woocommerce input[type='checkbox'].bulk-select__box{-webkit-appearance:none;-moz-appearance:none;appearance:none;height:16px;margin:0;min-width:16px;padding:0;width:16px}.wp-core-ui.wp-admin .wcc-root.woocommerce .extended-header .section-header__label::before{display:none}.wp-core-ui.wp-admin .wcc-root.woocommerce .extended-header .extended-header__header{font-size:18px;margin-bottom:0;padding-top:8px}.wp-core-ui.wp-admin .wcc-root.woocommerce .extended-header .extended-header__header-description{color:#636d75;font-size:12px;line-height:18px;padding-bottom:8px}.wp-core-ui.wp-admin .wcc-root.woocommerce .extended-header .section-header__actions{flex-shrink:0}.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input{display:flex;justify-content:flex-start;flex-wrap:wrap}.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input.no-wrap{flex-wrap:nowrap}.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input.no-wrap .form-dimensions-input__length,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input.no-wrap .form-dimensions-input__width{border-bottom-width:1px}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input{flex-wrap:nowrap}.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-text-input-with-affixes{flex-grow:2;flex-direction:row}}.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__length,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__width{border-bottom-width:0}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__length,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__width{border-bottom-width:1px}}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__width,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__height{margin-left:-1px}}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__length,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__width,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__height{width:75px;flex-grow:0}}.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__length:hover,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__length:focus,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__width:hover,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__width:focus,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__height:hover,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__height:focus{transform:scale(1)}.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__length:focus+.form-dimensions-input__width:hover,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__length:focus+.form-text-input-with-affixes .form-dimensions-input__height:hover,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__width:focus+.form-dimensions-input__width:hover,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__width:focus+.form-text-input-with-affixes .form-dimensions-input__height:hover,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__height:focus+.form-dimensions-input__width:hover,.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-dimensions-input__height:focus+.form-text-input-with-affixes .form-dimensions-input__height:hover{transform:none}.wp-core-ui.wp-admin .wcc-root.woocommerce .form-dimensions-input .form-text-input-with-affixes__suffix{flex-grow:0;background:inherit}.wp-core-ui.wp-admin .wcc-root .form-checkbox{margin-right:8px;cursor:pointer;display:inline-flex;align-items:center;position:relative;vertical-align:text-bottom}.wp-core-ui.wp-admin .wcc-root .form-checkbox input{margin:0}.wp-core-ui.wp-admin .wcc-root .form-checkbox input::before{display:none !important}.wp-core-ui.wp-admin .wcc-root .form-checkbox .gridicon{color:#016087;pointer-events:none;position:absolute}.wp-core-ui.wp-admin .wcc-root .form-checkbox .gridicon.gridicons-checkmark{left:1px;top:1px}.wp-core-ui.wp-admin .wcc-root .form-checkbox.is-disabled .gridicon{color:#b0b5b8}.wp-core-ui.wp-admin .wcc-root .field-error{color:#eb0001}.wp-core-ui.wp-admin .wcc-root .field-error__input-validation{padding:4px 0}.wp-core-ui.wp-admin .wcc-root .field-error__input-validation .gridicon{float:none;vertical-align:middle}.wp-core-ui.wp-admin .wcc-root .info-tooltip{cursor:help;color:#3d4145}.wp-core-ui.wp-admin .wcc-root.tooltip.popover.info-tooltip__container{z-index:100300}.wp-core-ui.wp-admin .wcc-root.tooltip.popover.info-tooltip__container .popover__inner{background:#3d4145}.wp-core-ui.wp-admin .wcc-root.tooltip.popover.info-tooltip__container .popover__arrow{border-top-color:#3d4145}.wp-core-ui.wp-admin .wcc-root.tooltip.popover.info-tooltip__container .info-tooltip__contents{padding:4px;color:#fff}.wp-core-ui.wp-admin .wcc-root.tooltip.popover.info-tooltip__container .info-tooltip__contents h1,.wp-core-ui.wp-admin .wcc-root.tooltip.popover.info-tooltip__container .info-tooltip__contents h2,.wp-core-ui.wp-admin .wcc-root.tooltip.popover.info-tooltip__container .info-tooltip__contents h3{margin:0 0 8px;color:#fff;font-weight:600;font-size:1.3em}.wp-core-ui.wp-admin .wcc-root.tooltip.popover.info-tooltip__container .info-tooltip__contents p{margin-top:0;margin-bottom:8px}.wp-core-ui.wp-admin .wcc-root.tooltip.popover.info-tooltip__container .info-tooltip__contents ul{list-style:disc;padding-left:16px}.wp-core-ui.wp-admin .wcc-root .card.is-compact.settings-group-card{margin-left:0;margin-right:0;max-width:100%;display:flex;padding-top:24px;padding-bottom:24px}@media (max-width: 660px){.wp-core-ui.wp-admin .wcc-root .card.is-compact.settings-group-card{flex-wrap:wrap}}.wp-core-ui.wp-admin .wcc-root .settings-group-card__heading{font-size:16px;font-weight:600;color:#636d75;width:22%;padding-right:10px;box-sizing:border-box}@media (max-width: 660px){.wp-core-ui.wp-admin .wcc-root .settings-group-card__heading{width:100%}}.wp-core-ui.wp-admin .wcc-root .settings-group-card__content{width:78%}@media (max-width: 660px){.wp-core-ui.wp-admin .wcc-root .settings-group-card__content{width:100%}}.wp-core-ui.wp-admin .wcc-root .settings-group-card__content .is-full-width{width:100%}.wp-core-ui.wp-admin .wcc-root .form-text-body-copy{font-size:14px;font-weight:400;line-height:1.5}.wp-core-ui.wp-admin .wcc-root .label-settings__credit-card-description{margin-bottom:4px;color:#636d75;padding-bottom:8px}.wp-core-ui.wp-admin .wcc-root .label-settings__credit-card-description button{color:#016087}.wp-core-ui.wp-admin .wcc-root .card.label-settings__card{margin-bottom:14px;display:flex;flex-direction:row;align-items:center;cursor:pointer}.wp-core-ui.wp-admin .wcc-root .label-settings__card .payment-logo{margin-top:0}.wp-core-ui.wp-admin .wcc-root .form-checkbox.label-settings__card-checkbox{margin-right:20px;float:left}.wp-core-ui.wp-admin .wcc-root .payment-logo{float:left;margin-top:10px;margin-right:14px}.wp-core-ui.wp-admin .wcc-root .label-settings__card-details{float:left;flex-grow:1}.wp-core-ui.wp-admin .wcc-root .label-settings__card-number{margin-bottom:0;font-weight:bold}.wp-core-ui.wp-admin .wcc-root .label-settings__card-name{margin-bottom:0}.wp-core-ui.wp-admin .wcc-root .label-settings__card-date{float:right;font-style:italic}.wp-core-ui.wp-admin .wcc-root .label-settings__labels-container.hidden{visibility:hidden;height:0;padding:0;overflow:hidden}.wp-core-ui.wp-admin .wcc-root .label-settings__labels-container .form-fieldset:last-child{margin-bottom:0}.wp-core-ui.wp-admin .wcc-root .label-settings__labels-container .label-settings__external{display:none}.wp-core-ui.wp-admin .wcc-root .label-settings__placeholder{animation:loading-fade 1.6s ease-in-out infinite;background-color:#e7e8e9;color:transparent;pointer-events:none;background:#fff}.wp-core-ui.wp-admin .wcc-root .label-settings__placeholder::after{content:'\A0'}.wp-core-ui.wp-admin .wcc-root .label-settings__placeholder::after{content:none}.wp-core-ui.wp-admin .wcc-root .label-settings__placeholder .gridicon,.wp-core-ui.wp-admin .wcc-root .label-settings__placeholder span,.wp-core-ui.wp-admin .wcc-root .label-settings__placeholder p,.wp-core-ui.wp-admin .wcc-root .label-settings__placeholder a,.wp-core-ui.wp-admin .wcc-root .label-settings__placeholder button{animation:loading-fade 1.6s ease-in-out infinite;background-color:#e1e2e2;color:transparent;cursor:default}.wp-core-ui.wp-admin .wcc-root .label-settings__placeholder p,.wp-core-ui.wp-admin .wcc-root .label-settings__placeholder span{display:block;width:100px;height:14px}.wp-core-ui.wp-admin .wcc-root .label-settings__placeholder button{width:200px;height:14px}.wp-core-ui.wp-admin .wcc-root .label-settings__placeholder .gridicon{fill:transparent;stroke:transparent}.wp-core-ui.wp-admin .wcc-root.dialog.card.add-credit-card-modal .dialog__content{max-width:720px;padding:0}.wp-core-ui.wp-admin .wcc-root .packages__add-package-weight{margin-bottom:8px}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .packages__add-package-weight{float:left}}.wp-core-ui.wp-admin .wcc-root .packages__add-package-weight:nth-child(1){width:100%}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .packages__add-package-weight:nth-child(1){width:50%}}.wp-core-ui.wp-admin .wcc-root .packages__add-package-weight:nth-child(2){width:100%}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .packages__add-package-weight:nth-child(2){width:50%}}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .packages__add-package-weight-group .form-setting-explanation{clear:both}}.wp-core-ui.wp-admin .wcc-root.packages__add-edit-dialog{height:90%;width:90%}.wp-core-ui.wp-admin .wcc-root.packages__add-edit-dialog .form-setting-explanation{display:inline-block}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root.packages__add-edit-dialog{width:610px;height:auto;padding:0}.wp-core-ui.wp-admin .wcc-root.packages__add-edit-dialog .dialog__content{padding:0}.wp-core-ui.wp-admin .wcc-root.packages__add-edit-dialog .dialog__content .packages__add-edit-title{padding:22px;margin:0;border-bottom:1px solid #EDEFF0;font-size:20px}.wp-core-ui.wp-admin .wcc-root.packages__add-edit-dialog .dialog__content .packages__mode-select .segmented-control__link{border-radius:0;border:0 none;padding:15px 0}.wp-core-ui.wp-admin .wcc-root.packages__add-edit-dialog .dialog__content .packages__mode-select .segmented-control__link:focus{box-shadow:none}.wp-core-ui.wp-admin .wcc-root.packages__add-edit-dialog .dialog__content .packages__mode-select .is-selected .segmented-control__link,.wp-core-ui.wp-admin .wcc-root.packages__add-edit-dialog .dialog__content .packages__mode-select .is-selected .segmented-control__link:focus{background-color:inherit;color:black;font-weight:bold;border-bottom:3px solid #96588A;outline:0}.wp-core-ui.wp-admin .wcc-root.packages__add-edit-dialog .dialog__content .packages__properties-group{margin:24px}}.wp-core-ui.wp-admin .wcc-root .packages__group-header-checkbox{margin-right:12px;vertical-align:text-bottom}.wp-core-ui.wp-admin .wcc-root .packages__packages-row{display:flex;flex-direction:row;padding:8px 0;align-items:center}.wp-core-ui.wp-admin .wcc-root .packages__packages-row:not(:last-child){border-bottom:1px solid #f6f6f6}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.packages__packages-header{border-bottom-color:#ccced0}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.prefixed:first-child{border-top:1px solid #f6f6f6}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.prefixed .form-checkbox{margin-left:16px}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .packages__packages-row.prefixed .form-checkbox{margin-left:24px}}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.prefixed .packages__packages-row-icon{padding-left:0;text-align:center;color:#636d75}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.prefixed .packages__packages-row-actions{width:38px;padding-right:8px}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.prefixed .packages__packages-row-details{width:50%}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.error{color:#eb0001}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.error a{color:#eb0001}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.error .packages__packages-row-icon .gridicon{background-color:unset;border-radius:unset;fill:#eb0001;padding:unset;margin-left:-1px}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.placeholder{animation:loading-fade 1.6s ease-in-out infinite;background-color:#e7e8e9;color:transparent;pointer-events:none;background:#fff}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.placeholder::after{content:'\A0'}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.placeholder .gridicon,.wp-core-ui.wp-admin .wcc-root .packages__packages-row.placeholder span,.wp-core-ui.wp-admin .wcc-root .packages__packages-row.placeholder p,.wp-core-ui.wp-admin .wcc-root .packages__packages-row.placeholder a,.wp-core-ui.wp-admin .wcc-root .packages__packages-row.placeholder button{animation:loading-fade 1.6s ease-in-out infinite;background-color:#e1e2e2;color:transparent;cursor:default}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.placeholder p,.wp-core-ui.wp-admin .wcc-root .packages__packages-row.placeholder span{display:block;width:100px;height:14px}.wp-core-ui.wp-admin .wcc-root .packages__packages-row.placeholder .gridicon{fill:transparent;stroke:transparent}.wp-core-ui.wp-admin .wcc-root .packages__packages-header{font-weight:600;padding:12px 0;font-size:14px;border-top:0;background:#f6f6f6}.wp-core-ui.wp-admin .wcc-root .packages__packages-row-icon{width:48px;text-align:left;padding-left:16px}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .packages__packages-row-icon{padding-left:24px}}.wp-core-ui.wp-admin .wcc-root .packages__packages-row-icon svg{margin-top:6px;width:24px}.wp-core-ui.wp-admin .wcc-root .packages__packages-row-details-name{margin-bottom:0;font-size:14px}.wp-core-ui.wp-admin .wcc-root .packages__packages-row-actions{width:25%;text-align:right;padding-right:16px}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .packages__packages-row-actions{padding-right:24px}}.wp-core-ui.wp-admin .wcc-root .packages__packages{padding:0}.wp-core-ui.wp-admin .wcc-root .packages__predefined-packages{margin-bottom:0}.wp-core-ui.wp-admin .wcc-root .packages__predefined-packages .packages__packages-header{border-top:1px solid #ccced0}.wp-core-ui.wp-admin .wcc-root .packages__predefined-packages .foldable-card__header .foldable-card__main{flex-grow:3}.wp-core-ui.wp-admin .wcc-root .packages__predefined-packages .foldable-card__header .foldable-card__secondary{flex-grow:2}.wp-core-ui.wp-admin .wcc-root .packages__predefined-packages .foldable-card__header .packages__group-header{display:flex;align-items:center}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .packages__predefined-packages .foldable-card__header{padding-left:24px}}.wp-core-ui.wp-admin .wcc-root .packages__predefined-packages .foldable-card__content{padding:0;border-top:0}.wp-core-ui.wp-admin .wcc-root .packages__packages-row-details{width:35%}.wp-core-ui.wp-admin .wcc-root .packages__packages-row-dimensions{width:30%;font-size:14px}.wp-core-ui.wp-admin .wcc-root .packages__setting-explanation{display:block;font-size:13px;font-style:italic;font-weight:400;margin:5px 0 0;color:#016087;text-decoration:underline}.wp-core-ui.wp-admin .wcc-root .packages__delete{float:left}.wp-core-ui.wp-admin .wcc-root .packages__mode-select{margin-bottom:12px}.wp-core-ui.wp-admin .wcc-root .settings-form__row{display:flex}.wp-core-ui.wp-admin .wcc-root .settings-form__row>*{flex-grow:1;margin-right:16px}.wp-core-ui.wp-admin .wcc-root .settings-form__row>*:last-child{margin-right:0}.wp-core-ui.wp-admin .wcc-root .shipping-services{margin-bottom:24px}.wp-core-ui.wp-admin .wcc-root .shipping-services .foldable-card{margin-left:0;margin-right:0;max-width:100%}.wp-core-ui.wp-admin .wcc-root .shipping-services__inner{margin-top:16px}.wp-core-ui.wp-admin .wcc-root .shipping-services__inner.is-error .card,.wp-core-ui.wp-admin .wcc-root .shipping-services__inner>.is-error .card:not(.is-expanded){border-top:1px;border-right:1px;border-left:1px;border-color:#eb0001;border-style:solid}.wp-core-ui.wp-admin .wcc-root .shipping-services__inner.is-error .card:last-child,.wp-core-ui.wp-admin .wcc-root .shipping-services__inner>.is-error .card:not(.is-expanded):last-child{border-bottom:1px solid #eb0001}.wp-core-ui.wp-admin .wcc-root .shipping-services__inner.is-error .card.is-expanded,.wp-core-ui.wp-admin .wcc-root .shipping-services__inner>.is-error .card:not(.is-expanded).is-expanded{border:1px solid #eb0001}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry{align-items:center;display:flex;width:100%}@media (max-width: 480px){.wp-core-ui.wp-admin .wcc-root .shipping-services__entry{padding:4px 0;border-bottom:1px solid #f6f6f6}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry:last-child{border-bottom:0}}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry.shipping-services__entry-header-container{display:inline-block;box-sizing:border-box;border-bottom:1px solid #f6f6f6;padding-bottom:8px;margin-bottom:4px}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry.shipping-services__entry-header-container .shipping-services__entry-header{display:inline-block;margin-left:0;font-weight:bold}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry.shipping-services__entry-header-container .shipping-services__entry-price-adjustment{float:right}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .shipping-services__entry.shipping-services__entry-header-container .shipping-services__entry-price-adjustment{padding-right:8px}}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry.shipping-services__entry-header-container .shipping-services__entry-price-adjustment-info{float:right;margin-left:4px;height:0}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry .form-checkbox{margin-right:8px}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry .form-checkbox .gridicon{top:0}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry .shipping-services__entry-title{flex-basis:70%;font-size:13px}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry .form-text-input{flex-basis:10%;margin:8px;padding:6px 12px;font-size:13px;min-width:42px}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry .form-select{flex-basis:20%;padding:6px 32px 5px 14px;line-height:22px;font-size:13px;box-shadow:none}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry .form-select:disabled{color:#b0b5b8;background-color:#f6f6f6;border-color:#f6f6f6}.wp-core-ui.wp-admin .wcc-root .shipping-services__entry.wcc-error input[type=text],.wp-core-ui.wp-admin .wcc-root .shipping-services__entry.wcc-error .gridicon{color:red}.wp-core-ui.wp-admin .wcc-root .shipping-services__delivery-estimate{color:#7c848b;margin-left:3px}.wp-core-ui.wp-admin .wcc-root .step-confirmation-button,.wp-core-ui.wp-admin .wcc-root .address-step__actions{padding:16px 24px;margin:0 -24px -24px;background:#f6f6f6;border-top:1px solid #f6f6f6}.wp-core-ui.wp-admin .wcc-root .step-confirmation-button .form-button,.wp-core-ui.wp-admin .wcc-root .address-step__actions .form-button{float:none;margin:0}.wp-core-ui.wp-admin .wcc-root .address-step__city-state-postal-code,.wp-core-ui.wp-admin .wcc-root .address-step__company-phone{display:flex;flex-direction:column}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .address-step__city-state-postal-code,.wp-core-ui.wp-admin .wcc-root .address-step__company-phone{flex-direction:row}}.wp-core-ui.wp-admin .wcc-root .notice.is-error{margin:6px 0 16px}.wp-core-ui.wp-admin .wcc-root .address-step__address-1.form-fieldset{margin-bottom:8px}.wp-core-ui.wp-admin .wcc-root .address-step__city,.wp-core-ui.wp-admin .wcc-root .address-step__state,.wp-core-ui.wp-admin .wcc-root .address-step__postal-code,.wp-core-ui.wp-admin .wcc-root .address-step__company,.wp-core-ui.wp-admin .wcc-root .address-step__phone{width:100%}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .address-step__city,.wp-core-ui.wp-admin .wcc-root .address-step__state,.wp-core-ui.wp-admin .wcc-root .address-step__postal-code,.wp-core-ui.wp-admin .wcc-root .address-step__company,.wp-core-ui.wp-admin .wcc-root .address-step__phone{margin-left:24px}}.wp-core-ui.wp-admin .wcc-root .address-step__city,.wp-core-ui.wp-admin .wcc-root .address-step__company{margin-left:0}.wp-core-ui.wp-admin .wcc-root .address-step__suggestion-container,.wp-core-ui.wp-admin .wcc-root .address-step__unverifiable-container{display:flex;align-items:flex-start;margin-top:24px;flex-direction:column}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .address-step__suggestion-container,.wp-core-ui.wp-admin .wcc-root .address-step__unverifiable-container{flex-direction:row}}.wp-core-ui.wp-admin .wcc-root .address-step__suggestion-title,.wp-core-ui.wp-admin .wcc-root .address-step__unverifiable-title{font-weight:bold}.wp-core-ui.wp-admin .wcc-root .address-step__suggestion,.wp-core-ui.wp-admin .wcc-root .address-step__unverifiable-info{padding:16px;flex-grow:1}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .address-step__suggestion,.wp-core-ui.wp-admin .wcc-root .address-step__unverifiable-info{flex-direction:row;width:50%}.wp-core-ui.wp-admin .wcc-root .address-step__suggestion:first-child,.wp-core-ui.wp-admin .wcc-root .address-step__unverifiable-info:first-child{margin-right:16px;margin-bottom:24px}}.wp-core-ui.wp-admin .wcc-root .address-step__suggestion{border:1px solid transparent;border-radius:4px;cursor:pointer;width:100%}.wp-core-ui.wp-admin .wcc-root .address-step__suggestion.is-selected{border-color:#016087}.wp-core-ui.wp-admin .wcc-root .address-step__suggestion-edit{margin-left:24px;color:#016087;font-weight:bold}.wp-core-ui.wp-admin .wcc-root .address-step__summary{margin:8px 0 8px 24px;font-weight:normal}.wp-core-ui.wp-admin .wcc-root .address-step__summary p{margin-bottom:2px}.wp-core-ui.wp-admin .wcc-root .address-step__summary .highlight{background-color:#f3f5f6}.wp-core-ui.wp-admin .wcc-root .address-step__unverifiable-info .external-link{float:left;clear:both}.wp-core-ui.wp-admin .wcc-root .address-step__unverifiable-info .address-step__summary{margin-left:0}.wp-core-ui.wp-admin .wcc-root .address-step__actions .form-button{margin-left:10px}.wp-core-ui.wp-admin .wcc-root .address-step__actions .form-button:first-child{margin-left:0}.wp-core-ui.wp-admin .wcc-root .packages-step__dialog-package-option{font-weight:normal;margin-bottom:10px}.wp-core-ui.wp-admin .wcc-root .packages-step__dialog-package-name{font-weight:bold}.wp-core-ui.wp-admin .wcc-root .packages-step__contents{display:flex;padding-bottom:24px;flex-direction:column}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .packages-step__contents{flex-direction:row}}.wp-core-ui.wp-admin .wcc-root .packages-step__list{width:auto;padding:0 0 24px;flex-shrink:0}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .packages-step__list{flex-direction:row;width:35%;padding:0 24px 0 0}}.wp-core-ui.wp-admin .wcc-root .packages-step__list-header{font-weight:600;margin-bottom:5px}.wp-core-ui.wp-admin .wcc-root .packages-step__list-package{display:flex;padding:6px 12px;cursor:pointer;align-items:center;width:100%}.wp-core-ui.wp-admin .wcc-root .packages-step__list-package.is-selected{background-color:#f6f6f6}.wp-core-ui.wp-admin .wcc-root .packages-step__list-package .gridicon{top:0}.wp-core-ui.wp-admin .wcc-root .packages-step__list-package-name{flex-grow:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-right:2px;text-align:left;color:#2b2d2f}.wp-core-ui.wp-admin .wcc-root .packages-step__list-package-count{display:inline-block;padding:1px 6px;border:solid 1px #b0b5b8;border-radius:12px;font-size:11px;font-weight:600;line-height:14px;color:#2b2d2f;text-align:center}.wp-core-ui.wp-admin .wcc-root .packages-step__package{flex-grow:1}.wp-core-ui.wp-admin .wcc-root .packages-step__package>div{margin-bottom:24px}.wp-core-ui.wp-admin .wcc-root .packages-step__package>div:last-child{margin-bottom:0}.wp-core-ui.wp-admin .wcc-root .packages-step__add-item-row{padding:8px 0;display:flex}.wp-core-ui.wp-admin .wcc-root .packages-step__no-items-message{padding:8px 0;font-style:italic;flex-grow:1}.wp-core-ui.wp-admin .wcc-root .packages-step__no-items-message .packages-step__add-item-btn{vertical-align:middle;margin-left:8px}.wp-core-ui.wp-admin .wcc-root .packages-step__package-item-description{font-weight:bold}.wp-core-ui.wp-admin .wcc-root .packages-step__package-items-header-name{width:60%;display:inline-block}.wp-core-ui.wp-admin .wcc-root .packages-step__package-items-header-weight{width:15%;display:inline-block;text-align:center}.wp-core-ui.wp-admin .wcc-root .packages-step__package-items-header-qty{width:15%;display:inline-block;text-align:center}.wp-core-ui.wp-admin .wcc-root .packages-step__package-items-header-move{width:10%;display:inline-block}.wp-core-ui.wp-admin .wcc-root .packages-step__item{display:flex;padding:0 0 8px}.wp-core-ui.wp-admin .wcc-root .packages-step__item:last-child{padding-bottom:0}.wp-core-ui.wp-admin .wcc-root .packages-step__item-name{padding:8px 0;width:70%}.wp-core-ui.wp-admin .wcc-root .packages-step__item-weight{padding:8px 0;width:15%;text-align:center}.wp-core-ui.wp-admin .wcc-root .packages-step__item-qty{padding:8px 0;width:15%;text-align:center}.wp-core-ui.wp-admin .wcc-root .packages-step__item-move{width:10%;margin:4px 0 4px 16px}.wp-core-ui.wp-admin .wcc-root .packages-step__package-weight{width:100%;margin-bottom:10px;float:left;margin-right:15px}@-moz-document url-prefix(){.wp-core-ui.wp-admin .wcc-root .packages-step__package-weight{width:135px;margin-right:65px}}.wp-core-ui.wp-admin .wcc-root .packages-step__package-weight-unit{margin-left:8px}.wp-core-ui.wp-admin .wcc-root .packages-step__package-signature{width:180px;float:left}.wp-core-ui.wp-admin .wcc-root .packages-step__no-packages{background:#f6f6f6;width:100%;text-align:center;padding:20px 0;display:flex;align-items:center;justify-content:center}.wp-core-ui.wp-admin .wcc-root .packages-step__no-packages>a{margin-left:8px}.wp-core-ui.wp-admin .wcc-root .packages-step__with-packages{margin-top:5px}.wp-core-ui.wp-admin .wcc-root .packages-step__package-details-header{display:flex;justify-content:space-between}.wp-core-ui.wp-admin .wcc-root .customs-step__package-container{margin-bottom:16px}.wp-core-ui.wp-admin .wcc-root .customs-step__package-container .info-tooltip{margin-left:4px}.wp-core-ui.wp-admin .wcc-root .customs-step__package-container:last-child{margin-bottom:0}.wp-core-ui.wp-admin .wcc-root .customs-step__package-name{font-size:16px;font-weight:600;margin-bottom:8px}.wp-core-ui.wp-admin .wcc-root .customs-step__restrictions-row{margin-top:16px;display:flex;flex-wrap:wrap}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .customs-step__restrictions-row{flex-wrap:nowrap}}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .customs-step__contents-type{margin-right:24px}}.wp-core-ui.wp-admin .wcc-root .customs-step__contents-type,.wp-core-ui.wp-admin .wcc-root .customs-step__restriction-type{width:100%}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .customs-step__contents-type,.wp-core-ui.wp-admin .wcc-root .customs-step__restriction-type{width:50%}}.wp-core-ui.wp-admin .wcc-root .customs-step__item-rows-header{display:none}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .customs-step__item-rows-header{display:flex}}.wp-core-ui.wp-admin .wcc-root .customs-step__item-rows-header span{font-size:14px;font-weight:600;margin-bottom:8px}.wp-core-ui.wp-admin .wcc-root .customs-step__item-row{display:flex;flex-direction:column}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .customs-step__item-row{flex-direction:row}.wp-core-ui.wp-admin .wcc-root .customs-step__item-row .form-legend,.wp-core-ui.wp-admin .wcc-root .customs-step__item-row .form-label{display:none}.wp-core-ui.wp-admin .wcc-root .customs-step__item-row .form-text-input-with-affixes__suffix{display:none}.wp-core-ui.wp-admin .wcc-root .customs-step__item-row .form-text-input-with-affixes__prefix{display:none}}.wp-core-ui.wp-admin .wcc-root .customs-step__item-description-column,.wp-core-ui.wp-admin .wcc-root .customs-step__item-country-column,.wp-core-ui.wp-admin .wcc-root .customs-step__item-weight-column,.wp-core-ui.wp-admin .wcc-root .customs-step__item-value-column,.wp-core-ui.wp-admin .wcc-root .customs-step__item-code-column{width:100%}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .customs-step__item-description-column,.wp-core-ui.wp-admin .wcc-root .customs-step__item-country-column,.wp-core-ui.wp-admin .wcc-root .customs-step__item-weight-column,.wp-core-ui.wp-admin .wcc-root .customs-step__item-value-column,.wp-core-ui.wp-admin .wcc-root .customs-step__item-code-column{margin-left:4px}}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .customs-step__item-weight-column,.wp-core-ui.wp-admin .wcc-root .customs-step__item-value-column,.wp-core-ui.wp-admin .wcc-root .customs-step__item-code-column{max-width:130px}}.wp-core-ui.wp-admin .wcc-root .customs-step__item-description-column{margin-left:0}.wp-core-ui.wp-admin .wcc-root .customs-step__abandon-on-non-delivery{font-weight:400}.wp-core-ui.wp-admin .wcc-root .rates-step__package-container{margin-bottom:20px}.wp-core-ui.wp-admin .wcc-root .rates-step__package-container .form-fieldset:last-child{margin-bottom:0}.wp-core-ui.wp-admin .wcc-root .rates-step__package-container .form-server-error{margin-left:-2px}.wp-core-ui.wp-admin .wcc-root .rates-step__package-container .form-fieldset ~ .form-server-error{margin-top:-1em}.wp-core-ui.wp-admin .wcc-root .rates-step__package-container-rates-header{font-weight:bold;margin-bottom:20px}.wp-core-ui.wp-admin .wcc-root .notice.rates-step__notice{margin:-24px -24px 24px;width:inherit}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-info-cost{font-weight:600}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-container{display:flex;align-items:stretch;height:100px}.wp-core-ui.wp-admin .wcc-root .rates-step__carier-logo-image-usps{width:40px;height:40px}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-information{display:flex;flex-grow:1;padding-left:8px;border-bottom:1px solid #EDEFF0;margin-bottom:12px}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-radio-control{padding:8px 8px 0 0}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-radio-control input[type='radio']{border:2px solid gray}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-radio-control input[type='radio']:checked{border-color:#d52c82}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-radio-control input[type='radio']:checked::before{margin:2px;background-color:#d52c82}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-description{display:flex;flex-direction:column}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-description-title{font-size:15px}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-description-details{color:#646970;font-size:12px}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-description-details * label{margin-left:5px}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-description-signature-select * select{color:#646970;font-size:12px;min-width:250px}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-details{display:flex;flex-direction:column;margin-left:auto}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-delivery-date{color:#646970;font-size:12px}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-rate-rate{text-align:right}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-info{display:flex;justify-content:center;align-items:center;height:56px;background:#EBF7F1;border:1px solid #008A20;box-sizing:border-box;border-radius:3px;margin-bottom:36px}.wp-core-ui.wp-admin .wcc-root .rates-step__shipping-info .gridicon{padding-right:8px;color:#008A20}.wp-core-ui.wp-admin .wcc-root.label-purchase-modal{height:calc(100% - 10vmin);width:calc(100% - 10vmin);max-height:1080px;max-width:1920px;background:#f6f7f7;box-shadow:rgba(151,150,150,0.5) 2px 2px 7px}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root.label-purchase-modal{background:linear-gradient(to right, #f6f7f7 0%, #f6f7f7 calc(60% - 32px), #fff calc(60% - 32px), #fff 100%)}}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root.label-purchase-modal{background:linear-gradient(to right, #f6f7f7 0%, #f6f7f7 calc(70% - 48px), #fff calc(70% - 48px), #fff 100%)}}.wp-core-ui.wp-admin .wcc-root.label-purchase-modal .dialog__content{flex-grow:1;display:flex;flex-direction:column}@media (max-width: 660px){.wp-core-ui.wp-admin .wcc-root.label-purchase-modal .dialog__content{padding:inherit;overflow-y:scroll}}@media (max-width: 660px){.wp-core-ui.wp-admin .wcc-root.label-purchase-modal.dialog.card{height:100%;max-height:100%;width:100%;max-width:100%}}.wp-core-ui.wp-admin .wcc-root.tracking-modal{height:60%;width:40%}.wp-core-ui.wp-admin .wcc-root.tracking-modal .dialog__content{flex-grow:1;display:flex;flex-direction:column}@media (max-width: 660px){.wp-core-ui.wp-admin .wcc-root.tracking-modal .dialog__content{padding:inherit;overflow-y:scroll}}@media (max-width: 660px){.wp-core-ui.wp-admin .wcc-root.tracking-modal.dialog.card{height:100%;max-height:100%;width:100%;max-width:100%}}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__sidebar{flex-basis:100%;padding:32px}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__sidebar{flex-basis:40%;padding:0 24px 24px;margin-top:-20px;margin-left:24px;background:#fff}}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__sidebar{flex-basis:30%}}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content{display:flex;flex-direction:column;height:100%;flex-grow:1}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .gridicon.is-success{color:#008a00}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .gridicon.is-warning{color:#f6c200}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .is-error:not(.notice){color:#eb0001}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .is-error .notice__icon,.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .is-warning .notice__icon,.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .is-success .notice__icon{display:block}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content select{width:100%}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .foldable-card__header{padding:12px 16px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .foldable-card__secondary{white-space:nowrap}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .foldable-card.is-expanded .foldable-card__content{padding:24px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .foldable-card__summary>span:first-child,.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .foldable-card__summary-expanded>span:first-child{display:flex;align-items:center;justify-content:flex-end}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .foldable-card__summary svg:empty,.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .foldable-card__summary-expanded svg:empty{display:none}@media (max-width: 660px){.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__content .form-section-heading{padding-top:20px;padding-left:20px}}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__body{display:flex;flex-grow:1}@media (max-width: 660px){.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__body{flex-direction:column}}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__main-section{flex-basis:100%}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__main-section{flex-basis:60%}}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__main-section{flex-basis:70%}}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__step-title,.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__step-status{float:left}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__step-status{margin:3px 0 0 5px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__step-title{margin:0 0 0 8px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__price-item{display:flex;margin-bottom:8px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__price-item.label-purchase-modal__price-item-total{font-weight:bold;margin-bottom:0;margin-top:24px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__price-item-addons{margin-left:20px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__price-item-help{color:#b0b5b8;cursor:help}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__price-item-help svg{margin-top:2px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__price-item-amount{flex-grow:1;text-align:right}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__header,.wp-core-ui.wp-admin .wcc-root .tracking-modal__header{display:flex;flex-direction:row}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__header .form-section-heading,.wp-core-ui.wp-admin .wcc-root .tracking-modal__header .form-section-heading{flex:1;margin:0 0 45px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__header .label-purchase-modal__close-button,.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__header .tracking-modal__close-button,.wp-core-ui.wp-admin .wcc-root .tracking-modal__header .label-purchase-modal__close-button,.wp-core-ui.wp-admin .wcc-root .tracking-modal__header .tracking-modal__close-button{border:none;padding:0;align-self:flex-start;margin-top:-7px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__shipping-summary-header{font-size:16px;font-weight:bold}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__shipping-summary-street{color:#636d75;margin-top:18px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__shipping-summary-street a{margin-left:7px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__shipping-summarry-labels{margin-top:18px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__shipping-summary-section{padding-bottom:15px}.wp-core-ui.wp-admin .wcc-root .shipping-label__payment .gridicon.notice__icon{align-self:flex-start;margin-top:8px}.wp-core-ui.wp-admin .wcc-root .shipping-label__item p{margin-bottom:3px;text-align:left}.wp-core-ui.wp-admin .wcc-root .shipping-label__item p.shipping-label__item-tracking{font-size:12px}.wp-core-ui.wp-admin .wcc-root .shipping-label__item p.shipping-label__item-tracking a:focus{outline:none;box-shadow:none}.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__new-label-button{width:100%;margin-top:16px}.wp-core-ui.wp-admin .wcc-root .shipping-label__item .ellipsis-menu__toggle{padding:0}.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__item-detail,.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__item-actions{display:flex;justify-content:space-between}.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__item-detail a,.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__item-actions a{display:inline-block;font-size:12px}.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__item-detail span svg,.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__item-detail a svg,.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__item-actions span svg,.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__item-actions a svg{position:relative;top:2px;margin-right:2px}.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__item-detail{margin-bottom:6px}.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__item-detail a{vertical-align:text-top}.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__item-actions{margin-bottom:0}.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__item-actions a{margin-top:10px}.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__purchase-error{color:#eb0001;cursor:help;text-decoration:underline;-webkit-text-decoration-color:#eb0001;text-decoration-color:#eb0001;-webkit-text-decoration-style:dotted;text-decoration-style:dotted}.wp-core-ui.wp-admin .wcc-root.dialog.card.label-reprint-modal .shipping-label__reprint-modal-notice{color:#7c848b;font-style:italic}.wp-core-ui.wp-admin .wcc-root.dialog.card.label-refund-modal dd{margin-left:0}.wp-core-ui.wp-admin .wcc-root.dialog.card.label-details-modal{width:460px}.wp-core-ui.wp-admin .wcc-root.dialog.card.label-details-modal dd{margin-left:0}.wp-core-ui.wp-admin .wcc-root.dialog.card.label-details-modal dd ul{margin-left:1.2em}.wp-core-ui.wp-admin .wcc-root .error-notice{width:inherit}.wp-core-ui.wp-admin .wcc-root .shipping-label__loading-spinner{margin:8px auto;text-align:center}.wp-core-ui.wp-admin .wcc-root .shipping-label__label-details-modal-heading{display:flex}.wp-core-ui.wp-admin .wcc-root .shipping-label__label-details-modal-heading-title{flex-grow:1}.wp-core-ui.wp-admin .wcc-root .foldable-card.card.order-activity-log__day-header,.wp-core-ui.wp-admin .wcc-root .foldable-card.card.order-activity-log__day-header.is-expanded{margin:0 0 16px}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .foldable-card.card.order-activity-log__day-header,.wp-core-ui.wp-admin .wcc-root .foldable-card.card.order-activity-log__day-header.is-expanded{margin:0 0 24px}}.wp-core-ui.wp-admin .wcc-root .order-activity-log__day .foldable-card__content{position:relative;z-index:0}.wp-core-ui.wp-admin .wcc-root .order-activity-log__day .foldable-card__content::before{content:'';z-index:-1;position:absolute;top:0;left:45px;bottom:0;width:1px;background:rgba(204,206,208, 0.5)}.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .foldable-card__main h3,.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .foldable-card__main small,.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .order-activity-log__note-time,.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .order-activity-log__note-type,.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .order-activity-log__note-content,.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .order-activity-log__note-meta .gridicon{animation:loading-fade 1.6s ease-in-out infinite;background-color:#e7e8e9;color:transparent}.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .foldable-card__main h3::after,.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .foldable-card__main small::after,.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .order-activity-log__note-time::after,.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .order-activity-log__note-type::after,.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .order-activity-log__note-content::after,.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .order-activity-log__note-meta .gridicon::after{content:'\A0'}.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .order-activity-log__note-time{height:1.3em}.wp-core-ui.wp-admin .wcc-root .order-activity-log .is-placeholder .order-activity-log__note-meta .gridicon{fill:transparent}.wp-core-ui.wp-admin .wcc-root .order-activity-log__note{display:flex}.wp-core-ui.wp-admin .wcc-root .order-activity-log__note+.order-activity-log__note{margin-top:16px}.wp-core-ui.wp-admin .wcc-root .order-activity-log__note .order-activity-log__note-meta{flex:1 0 60px;width:60px;text-align:center}.wp-core-ui.wp-admin .wcc-root .order-activity-log__note .order-activity-log__note-meta .gridicon{display:inline-block;padding:4px;background:#016087;fill:#fff;border-radius:50%;border:4px solid white}.wp-core-ui.wp-admin .wcc-root .order-activity-log__note .order-activity-log__note-time{display:block;font-size:12px;background:white}.wp-core-ui.wp-admin .wcc-root .order-activity-log__note .order-activity-log__note-body{flex:1 0 calc( 100% - 76px);width:calc( 100% - 76px);box-sizing:border-box;margin-left:16px;padding:12px 16px 16px;box-shadow:0 0 0 1px rgba(204,206,208, 0.5)}.wp-core-ui.wp-admin .wcc-root .order-activity-log__note .order-activity-log__note-type{font-size:12px;color:#636d75;text-transform:uppercase}.wp-core-ui.wp-admin .wcc-root .order-activity-log__note .order-activity-log__note-content{margin:8px 8px 0 0}.wp-core-ui.wp-admin .wcc-root .order-activity-log__new-note-content{margin:0 -15px 16px;border:1px solid #e1e2e2;border-width:1px 0}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .order-activity-log__new-note-content{margin:0 -24px 24px}}.wp-core-ui.wp-admin .wcc-root .order-activity-log__new-note-content .form-label{padding:0 24px;margin-bottom:8px}.wp-core-ui.wp-admin .wcc-root .order-activity-log__new-note-content .form-textarea{padding:16px;border-color:#fff;resize:vertical;display:block;font-size:14px}.wp-core-ui.wp-admin .wcc-root .order-activity-log__new-note-content .form-textarea:-ms-input-placeholder{color:#636d75}.wp-core-ui.wp-admin .wcc-root .order-activity-log__new-note-content .form-textarea::placeholder{color:#636d75}.wp-core-ui.wp-admin .wcc-root .order-activity-log__new-note-content .form-textarea:focus{border-color:#016087}@media (min-width: 481px){.wp-core-ui.wp-admin .wcc-root .order-activity-log__new-note-content .form-textarea{padding:16px 24px}}.wp-core-ui.wp-admin .wcc-root .order-activity-log__new-note-type .button{float:right}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-heading,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-heading{font-size:14px;font-weight:600;margin-bottom:8px}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-body,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-body,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body{background:#f6f6f6;display:flex;margin-bottom:16px;padding:12px}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-body .stripe__connect-account-logo-container,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-body .stripe__connect-account-logo-container,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body .stripe__connect-account-logo-container{align-items:center;background:#fff;border:1px solid #ccced0;display:flex;height:46px;justify-content:center;margin-right:12px;width:46px}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-body .stripe__connect-account-logo-container .stripe__connect-account-logo,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-body .stripe__connect-account-logo-container .stripe__connect-account-logo,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body .stripe__connect-account-logo-container .stripe__connect-account-logo{max-height:36px;max-width:36px}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-body .stripe__connect-account-details,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-body .stripe__connect-account-details,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body .stripe__connect-account-details{display:flex;flex-direction:column}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-body .stripe__connect-account-details .stripe__connect-account-name,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-body .stripe__connect-account-details .stripe__connect-account-name,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body .stripe__connect-account-details .stripe__connect-account-name{font-size:14px;font-weight:400;margin-bottom:1px;margin-right:4px}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-body .stripe__connect-account-details .stripe__connect-account-email,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-body .stripe__connect-account-details .stripe__connect-account-email,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body .stripe__connect-account-details .stripe__connect-account-email{color:#636d75}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-body .stripe__connect-account-details .stripe__connect-account-status,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-body .stripe__connect-account-details .stripe__connect-account-status,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body .stripe__connect-account-details .stripe__connect-account-status{border-radius:3px;color:#fff;font-size:12px;margin-right:8px;padding:3px 8px}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-body .stripe__connect-account-details .stripe__connect-account-status.account-activated,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-body .stripe__connect-account-details .stripe__connect-account-status.account-activated,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body .stripe__connect-account-details .stripe__connect-account-status.account-activated{background-color:#008a00}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-body .stripe__connect-account-details .stripe__connect-account-status.account-not-activated,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-body .stripe__connect-account-details .stripe__connect-account-status.account-not-activated,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body .stripe__connect-account-details .stripe__connect-account-status.account-not-activated{background-color:#f6c200}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-body .stripe__connect-account-details .stripe__connect-account-disconnect,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-body .stripe__connect-account-details .stripe__connect-account-disconnect,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body .stripe__connect-account-details .stripe__connect-account-disconnect{font-size:12px;padding-top:3px;padding-bottom:0}.wp-core-ui.wp-admin .wcc-root .stripe__connect-prompt ul{margin-bottom:16px}.wp-core-ui.wp-admin .wcc-root .stripe__method-edit-header{font-size:18px;justify-content:space-between;padding:0 0 16px}.wp-core-ui.wp-admin .wcc-root .stripe__method-edit-header.placeholder{margin-bottom:16px;width:30%;animation:loading-fade 1.6s ease-in-out infinite;background-color:#e7e8e9;color:transparent}.wp-core-ui.wp-admin .wcc-root .stripe__method-edit-header.placeholder::after{content:'\A0'}.wp-core-ui.wp-admin .wcc-root .stripe__method-edit-body{padding:0 0 16px}.wp-core-ui.wp-admin .wcc-root .stripe__method-edit-body.placeholder{height:60px;animation:loading-fade 1.6s ease-in-out infinite;background-color:#e7e8e9;color:transparent}.wp-core-ui.wp-admin .wcc-root .stripe__method-edit-body.placeholder::after{content:'\A0'}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator{margin-top:4px;margin-bottom:4px}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator .form-setting-explanation{margin-top:0}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator .form-setting-explanation a{font-style:normal}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator .plugin-status__indicator-message{margin:0 0 4px 4px}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator.is-success .plugin-status__indicator-icon-and-message{fill:#008a00}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator.is-success .plugin-status__indicator-icon-and-message .gridicon{fill:#008a00}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator.is-warning .plugin-status__indicator-icon-and-message{color:#f6c200}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator.is-warning .plugin-status__indicator-icon-and-message .gridicon{fill:#f6c200}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator.is-error .plugin-status__indicator-icon-and-message{color:#eb0001}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator.is-error .plugin-status__indicator-icon-and-message .gridicon{fill:#eb0001}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator-icon-and-message{display:flex;align-items:center}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator-icon-and-message .indicator__icon{margin-right:6px}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator-icon-and-message .indicator__message{margin-top:-4px}.wp-core-ui.wp-admin .wcc-root .plugin-status__indicator-subtitle{background:#f6f6f6;border-radius:2px;color:#3d4145;font-size:11px;font-weight:400;margin-left:8px;padding:2px 8px}.wp-core-ui.wp-admin .wcc-root .plugin-status__help-description{font-size:14px;font-weight:400;line-height:1.5}.wp-core-ui.wp-admin .wcc-root .plugin-status__log-explanation{display:flex}.wp-core-ui.wp-admin .wcc-root .plugin-status__log-explanation-span{flex-grow:1}.wp-core-ui.wp-admin .wcc-root .form-textarea{font-size:12px;height:195px;resize:none;white-space:pre}.wp-core-ui.wp-admin .wcc-root .form-textarea#wcc_debug_log_tail{font-family:Consolas, "Andale Mono WT", "Andale Mono", "Lucida Console", Monaco, "Courier New", Courier, monospace}.wp-core-ui.wp-admin .wcc-root .shipping-label__container{margin-bottom:0;text-align:center;display:flex;justify-content:space-between}.wp-core-ui.wp-admin .wcc-root .shipping-label__container em{font-size:18px;display:inline-block;vertical-align:text-bottom;margin-left:10px;padding-bottom:11px;position:relative;top:3px;font-style:normal}.wp-core-ui.wp-admin .wcc-root .shipping-label__container .shipping-label__payment .gridicon.notice__icon{align-self:flex-start;margin-top:8px}.wp-core-ui.wp-admin .wcc-root .shipping-label__container .shipping-label__new{padding:16px;border-bottom:1px solid #eee}.wp-core-ui.wp-admin .wcc-root .shipping-label__container .shipping-label__new .shipping-label__new-label-button{width:100%;margin-top:16px}.wp-core-ui.wp-admin .wcc-root .shipping-label__container .shipping-label__new .shipping-label__new-label-button.is-placeholder{animation:loading-fade 1.6s ease-in-out infinite;background-color:#e7e8e9;color:transparent}.wp-core-ui.wp-admin .wcc-root .shipping-label__container .shipping-label__new .shipping-label__new-label-button.is-placeholder::after{content:'\A0'}.wp-core-ui.wp-admin .wcc-root .shipping-label__container .shipping-label__new p{margin-bottom:3px;text-align:left}.wp-core-ui.wp-admin .wcc-root .shipping-label__multiple-buttons-container button{margin-left:10px}.wp-core-ui.wp-admin .wcc-root .shipping-label__redo-shipping-button .button.is-borderless{margin-right:8px;color:#777}.wp-core-ui.wp-admin .wcc-root.label-purchase-modal,.wp-core-ui.wp-admin .wcc-root.packages-step__dialog{font-size:15px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__option-email-customer,.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__option-mark-order-fulfilled{display:none}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__purchase-container{display:flex;align-items:flex-end;justify-content:center}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__purchase-container .form-fieldset{margin:0 5px 0 0;width:50%}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__purchase-container .purchase-section{width:50%;margin-left:5px}.wp-core-ui.wp-admin .wcc-root .label-purchase-modal__purchase-container .purchase-section .button{width:100%}.wp-core-ui.wp-admin .wcc-root .order-activity-log .foldable-card .foldable-card__content{padding-left:0;padding-right:8px}.wp-core-ui.wp-admin .wcc-root .order-activity-log .foldable-card .foldable-card__content:before{left:30px}.wp-core-ui.wp-admin .wcc-root .order-activity-log .foldable-card.card.order-activity-log__day-header{margin:0}.wp-core-ui.wp-admin .wcc-root .order-activity-log .order-activity-log__note-body{margin-left:0;padding-left:8px;padding-right:8px}.wp-core-ui.wp-admin .wcc-root .order-activity-log .order-activity-log__note-body .order-activity-log__note-content{margin:0}.wp-core-ui.wp-admin .wcc-root .order-activity-log .order-activity-log__note-meta{flex-basis:48px}.wp-core-ui.wp-admin .wcc-root .shipping-label__item .shipping-label__button{padding:0;font-weight:normal;font-size:13px;line-height:19px}.wp-core-ui.wp-admin .wcc-root .shipping-label__button-loading{height:40px;min-width:162px}@media (max-width: 1080px){.wp-core-ui.wp-admin .wcc-root .shipping-label__container{display:block}}.wp-core-ui.wp-admin .wcc-root .print-test-label__form-container{display:flex}.wp-core-ui.wp-admin .wcc-root .print-test-label__form-container .print-test-label__paper-size{width:auto}.wp-core-ui.wp-admin .wcc-root .settings__placeholder .form-label,.wp-core-ui.wp-admin .wcc-root .settings__placeholder .form-text-input{animation:loading-fade 1.6s ease-in-out infinite;background-color:#e7e8e9;color:transparent;pointer-events:none}.wp-core-ui.wp-admin .wcc-root .settings__placeholder .form-label::after,.wp-core-ui.wp-admin .wcc-root .settings__placeholder .form-text-input::after{content:'\A0'}.wp-core-ui.wp-admin .wcc-root .settings__button-row{background:#f6f6f6;padding:16px 24px;margin-right:0;margin-left:0;max-width:100%}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-heading,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-heading{display:none}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-body,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-body,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body{max-width:545px;border:1px solid #ccc;line-height:1.5}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-status,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-status{vertical-align:sub}.wp-core-ui.wp-admin .wcc-root .stripe__connect-account .stripe__connect-account-disconnect,.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe__connect-account-disconnect{line-height:21px;display:inline-block;vertical-align:bottom}.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body{animation:loading-fade 1.6s ease-in-out infinite;background-color:#e7e8e9;color:transparent}.wp-core-ui.wp-admin .wcc-root .stripe-connect-account__placeholder-container .stripe-connect-account__placeholder-body::after{content:'\A0'}.wp-core-ui.wp-admin .wcc-root .toggle__text{color:#969ca1;font-size:11px;line-height:16px;margin-left:8px;vertical-align:middle;text-transform:uppercase}.dialog__backdrop{align-items:center;bottom:0;left:0;display:flex;justify-content:center;position:fixed;right:0;top:46px;transition:background-color 0.2s ease-in;z-index:100200}.dialog__backdrop.dialog-enter,.dialog__backdrop.dialog-leave.dialog-leave-active{background-color:rgba(246,246,246, 0)}.dialog__backdrop,.dialog__backdrop.dialog-enter.dialog-enter-active,.dialog__backdrop.dialog-leave{background-color:rgba(246,246,246, 0.8)}.dialog__backdrop.is-full-screen{top:0}.dialog__backdrop.is-hidden{background-color:transparent}.dialog.card{position:relative;display:flex;flex-direction:column;max-width:90%;max-height:90%;margin:auto 0;padding:0;opacity:1;transition:opacity 0.2s ease-in}.dialog-enter .dialog.card,.dialog-leave.dialog-leave-active .dialog.card{opacity:0}.dialog.card,.dialog-enter.dialog-enter-active .dialog.card,.dialog-leave .dialog.card{opacity:1}.dialog__content{padding:16px;overflow-y:auto}@media (min-width: 481px){.dialog__content{padding:24px}}.dialog__content:last-child{bottom:0}.dialog__content h1{color:#3d4145;font-size:1.375em;font-weight:600;line-height:2em;margin-bottom:0.5em}.dialog__content p:last-child{margin-bottom:0}.dialog__action-buttons{position:relative;border-top:1px solid #f6f6f6;padding:16px;margin:0;text-align:right;flex-shrink:0;background-color:#fff}@media (min-width: 481px){.dialog__action-buttons{padding-left:24px;padding-right:24px}}@media (max-width: 480px){.dialog__action-buttons{display:flex;flex-direction:column-reverse}}.dialog__action-buttons::before{content:'';display:block;position:absolute;bottom:100%;left:16px;right:16px;height:24px;background:linear-gradient(to bottom, rgba(255,255,255,0) 0%, #fff 100%);margin-bottom:1px}.dialog__action-buttons .button{margin-left:10px;min-width:80px;text-align:center}.dialog__action-buttons .button .is-left-aligned{margin-left:0;margin-right:10px}@media (max-width: 480px){.dialog__action-buttons .button{margin:2px 0}}.dialog__action-buttons .is-left-aligned{float:left}.ReactModal__Body--open{overflow:hidden}.ReactModal__Html--open{overflow:visible}.popover{font-size:11px;z-index:1000;position:absolute;top:0;left:0 /*rtl:ignore*/;right:auto /*rtl:ignore*/}.popover .popover__inner{background-color:#fff;border:1px solid #ccced0;border-radius:4px;box-shadow:0 2px 5px rgba(0,0,0,0.1),0 0 56px rgba(0,0,0,0.075);text-align:center;position:relative}.popover .popover__arrow{border:10px dashed #ccced0;height:0;line-height:0;position:absolute;width:0;z-index:1}.popover.fade{transition:opacity 100ms}.popover.is-top .popover__arrow,.popover.is-top-left .popover__arrow,.popover.is-top-right .popover__arrow{bottom:0 /*rtl:ignore*/;left:50% /*rtl:ignore*/;margin-left:-10px/*rtl:ignore*/;border-top-style:solid/*rtl:ignore*/;border-bottom:none/*rtl:ignore*/;border-left-color:transparent/*rtl:ignore*/;border-right-color:transparent/*rtl:ignore*/}.popover.is-top .popover__arrow::before,.popover.is-top-left .popover__arrow::before,.popover.is-top-right .popover__arrow::before{bottom:2px /*rtl:ignore*/;border:10px solid #fff;content:' ';position:absolute;left:50% /*rtl:ignore*/;margin-left:-10px/*rtl:ignore*/;border-top-style:solid/*rtl:ignore*/;border-bottom:none/*rtl:ignore*/;border-left-color:transparent/*rtl:ignore*/;border-right-color:transparent/*rtl:ignore*/}.popover.is-bottom .popover__arrow,.popover.is-bottom-left .popover__arrow,.popover.is-bottom-right .popover__arrow{top:0 /*rtl:ignore*/;left:50% /*rtl:ignore*/;margin-left:-10px/*rtl:ignore*/;border-bottom-style:solid/*rtl:ignore*/;border-top:none/*rtl:ignore*/;border-left-color:transparent/*rtl:ignore*/;border-right-color:transparent/*rtl:ignore*/}.popover.is-bottom .popover__arrow::before,.popover.is-bottom-left .popover__arrow::before,.popover.is-bottom-right .popover__arrow::before{top:2px /*rtl:ignore*/;border:10px solid #fff;content:' ';position:absolute;left:50% /*rtl:ignore*/;margin-left:-10px/*rtl:ignore*/;border-bottom-style:solid/*rtl:ignore*/;border-top:none/*rtl:ignore*/;border-left-color:transparent/*rtl:ignore*/;border-right-color:transparent/*rtl:ignore*/}.popover.is-left .popover__arrow,.popover.is-left-top .popover__arrow,.popover.is-left-bottom .popover__arrow{right:0 /*rtl:ignore*/;top:50% /*rtl:ignore*/;margin-top:-10px/*rtl:ignore*/;border-left-style:solid/*rtl:ignore*/;border-right:none/*rtl:ignore*/;border-top-color:transparent/*rtl:ignore*/;border-bottom-color:transparent/*rtl:ignore*/}.popover.is-left .popover__arrow::before,.popover.is-left-top .popover__arrow::before,.popover.is-left-bottom .popover__arrow::before{right:2px /*rtl:ignore*/;border:10px solid #fff;content:' ';position:absolute;top:50% /*rtl:ignore*/;margin-top:-10px/*rtl:ignore*/;border-left-style:solid/*rtl:ignore*/;border-right:none/*rtl:ignore*/;border-top-color:transparent/*rtl:ignore*/;border-bottom-color:transparent/*rtl:ignore*/}.popover.is-right .popover__arrow,.popover.is-right-top .popover__arrow,.popover.is-right-bottom .popover__arrow{left:0 /*rtl:ignore*/;top:50% /*rtl:ignore*/;margin-top:-10px/*rtl:ignore*/;border-right-style:solid/*rtl:ignore*/;border-left:none/*rtl:ignore*/;border-top-color:transparent/*rtl:ignore*/;border-bottom-color:transparent/*rtl:ignore*/}.popover.is-right .popover__arrow::before,.popover.is-right-top .popover__arrow::before,.popover.is-right-bottom .popover__arrow::before{left:2px /*rtl:ignore*/;border:10px solid #fff;content:' ';position:absolute;top:50% /*rtl:ignore*/;margin-top:-10px/*rtl:ignore*/;border-right-style:solid/*rtl:ignore*/;border-left:none/*rtl:ignore*/;border-top-color:transparent/*rtl:ignore*/;border-bottom-color:transparent/*rtl:ignore*/}.popover.is-top-left,.popover.is-bottom-left,.popover.is-top-right,.popover.is-bottom-right{padding-right:0;padding-left:0}.popover.is-top-left .popover__arrow,.popover.is-bottom-left .popover__arrow{left:auto /*rtl:ignore*/;right:5px /*rtl:ignore*/}.popover.is-top-right .popover__arrow,.popover.is-bottom-right .popover__arrow{left:15px /*rtl:ignore*/}.popover.is-top .popover__inner,.popover.is-top-left .popover__inner,.popover.is-top-right .popover__inner{top:-10px /*rtl:ignore*/}.popover.is-left .popover__inner,.popover.is-top-right .popover__inner,.popover.is-bottom-right .popover__inner{left:-10px /*rtl:ignore*/}.popover.is-bottom .popover__inner,.popover.is-bottom-left .popover__inner,.popover.is-bottom-right .popover__inner{top:10px /*rtl:ignore*/}.popover.is-right .popover__inner,.popover.is-top-left .popover__inner,.popover.is-bottom-left .popover__inner{left:10px /*rtl:ignore*/}.popover.is-dialog-visible{z-index:100300}.popover__menu{display:flex;flex-direction:column;min-width:200px}.popover__menu-item{position:relative;background:inherit;border:none;border-radius:0;cursor:pointer;display:block;font-size:14px;font-weight:400;margin:0;padding:8px 16px;text-align:left;text-decoration:none;line-height:normal;transition:all 0.05s ease-in-out}.popover__menu-item:first-child{margin-top:5px}.popover__menu-item,.popover__menu-item:visited{color:#3d4145}.popover__menu-item.is-selected,.popover__menu-item:hover,.popover__menu-item:focus{background-color:#016087;border:0;box-shadow:none;color:white}.popover__menu-item.is-selected .gridicon,.popover__menu-item:hover .gridicon,.popover__menu-item:focus .gridicon{color:#fff}.popover__menu-item[disabled]{color:#f6f6f6}.popover__menu-item[disabled] .gridicon{color:#f6f6f6}.popover__menu-item[disabled]:hover,.popover__menu-item[disabled]:focus{background:transparent;cursor:default}.popover__menu-item:last-child{margin-bottom:5px}.popover__menu-item::-moz-focus-inner{border:0}.popover__menu-item .gridicon{color:#b0b5b8;vertical-align:bottom;margin-right:8px}.popover__menu-item .gridicons-cloud-download{position:relative;top:2px}.popover__menu-item .gridicons-external{top:0}.popover__menu-separator,.popover__hr{margin:4px 0;background:#f6f6f6}.tooltip.popover .popover__arrow{border-width:6px}.tooltip.popover.is-bottom-right .popover__arrow,.tooltip.popover.is-bottom-left .popover__arrow,.tooltip.popover.is-bottom .popover__arrow{border-bottom-color:#50575d;top:4px;right:10px}.tooltip.popover.is-bottom-right .popover__arrow::before,.tooltip.popover.is-bottom-left .popover__arrow::before,.tooltip.popover.is-bottom .popover__arrow::before{display:none}.tooltip.popover.is-bottom-right.is-error .popover__arrow,.tooltip.popover.is-bottom-left.is-error .popover__arrow,.tooltip.popover.is-bottom.is-error .popover__arrow{border-bottom-color:#eb0001}.tooltip.popover.is-bottom-right.is-warning .popover__arrow,.tooltip.popover.is-bottom-left.is-warning .popover__arrow,.tooltip.popover.is-bottom.is-warning .popover__arrow{border-bottom-color:#f6c200}.tooltip.popover.is-bottom-right.is-success .popover__arrow,.tooltip.popover.is-bottom-left.is-success .popover__arrow,.tooltip.popover.is-bottom.is-success .popover__arrow{border-bottom-color:#008a00}.tooltip.popover.is-top .popover__arrow,.tooltip.popover.is-top-left .popover__arrow,.tooltip.popover.is-top-right .popover__arrow{border-top-color:#50575d;bottom:4px;right:10px}.tooltip.popover.is-top .popover__arrow::before,.tooltip.popover.is-top-left .popover__arrow::before,.tooltip.popover.is-top-right .popover__arrow::before{display:none}.tooltip.popover.is-top.is-error .popover__arrow,.tooltip.popover.is-top-left.is-error .popover__arrow,.tooltip.popover.is-top-right.is-error .popover__arrow{border-top-color:#eb0001}.tooltip.popover.is-top.is-warning .popover__arrow,.tooltip.popover.is-top-left.is-warning .popover__arrow,.tooltip.popover.is-top-right.is-warning .popover__arrow{border-top-color:#f6c200}.tooltip.popover.is-top.is-success .popover__arrow,.tooltip.popover.is-top-left.is-success .popover__arrow,.tooltip.popover.is-top-right.is-success .popover__arrow{border-top-color:#008a00}.tooltip.popover.is-top .popover__arrow,.tooltip.popover.is-bottom .popover__arrow{margin-left:-6px}.tooltip.popover.is-left,.tooltip.popover.is-right{padding-top:0}.tooltip.popover.is-left .popover__arrow,.tooltip.popover.is-right .popover__arrow{margin-top:-6px}.tooltip.popover.is-left .popover__arrow::before,.tooltip.popover.is-right .popover__arrow::before{display:none}.tooltip.popover.is-left.is-error .popover__arrow,.tooltip.popover.is-right.is-error .popover__arrow{border-right-color:#eb0001}.tooltip.popover.is-left.is-warning .popover__arrow,.tooltip.popover.is-right.is-warning .popover__arrow{border-right-color:#f6c200}.tooltip.popover.is-left.is-success .popover__arrow,.tooltip.popover.is-right.is-success .popover__arrow{border-right-color:#008a00}.tooltip.popover.is-left .popover__arrow{margin-right:4px;border-left-color:#50575d}.tooltip.popover.is-right .popover__arrow{margin-left:4px;border-right-color:#50575d}.tooltip.popover .popover__inner{border:0;box-shadow:none;border-radius:2px;color:#fff;background:#50575d;font-size:12px;padding:6px 10px;text-align:left}.tooltip.popover.is-error .popover__inner{background:#eb0001}.tooltip.popover.is-warning .popover__inner{background:#f6c200}.tooltip.popover.is-success .popover__inner{background:#008a00}.tooltip.popover ul{list-style:none;margin:0;padding:0}.tooltip.popover ul li{font-size:11px;font-weight:100;border:0;padding:2px 0}.tooltip__hr{margin:8px 0;background:#969ca1}#woocommerce-order-label .inside{margin:0;padding:0}.wc-connect-admin-dev-notice{width:700px}.wc-connect-admin-dev-notice p{font-style:italic;color:#969ca1}.wcs-pointer-page-dimmer{display:none;position:fixed;background-color:black;top:0;bottom:0;left:0;right:0;z-index:9998;opacity:0.5}.gridicon{fill:currentColor}#woocommerce-services-shipping-debug .packing-log{white-space:pre-wrap}.wp-core-ui.wp-admin #side-sortables .wcc-root .shipping-label__container{display:block}.wp-core-ui.wp-admin #woocommerce-order-shipment-tracking .wcc-root.wc-connect-create-shipping-label{padding:0}.wp-core-ui.wp-admin #woocommerce-order-shipment-tracking .wcc-root.wc-connect-create-shipping-label .shipping-label__container .button.is-placeholder,.wp-core-ui.wp-admin #woocommerce-order-shipment-tracking .wcc-root.wc-connect-create-shipping-label .shipping-label__container .button.is-primary{border-width:1px;border-style:solid;border-radius:3px;background:#0085ba;border-color:#0073aa #006799 #006799;box-shadow:0 1px 0 #006799;color:#fff;text-decoration:none;text-shadow:0 -1px 1px #006799, 1px 0 1px #006799, 0 1px 1px #006799, -1px 0 1px #006799}
2
+
3
+ .wp-core-ui.wp-admin .wcc-root .screen-reader-text{clip:rect(1px, 1px, 1px, 1px);position:absolute !important}.wp-core-ui.wp-admin .wcc-root .screen-reader-text:hover,.wp-core-ui.wp-admin .wcc-root .screen-reader-text:active,.wp-core-ui.wp-admin .wcc-root .screen-reader-text:focus{background-color:#f1f1f1;border-radius:3px;box-shadow:0 0 2px 2px rgba(0,0,0,0.6);clip:auto !important;color:#21759b;display:block;font-size:14px;font-weight:bold;height:auto;left:5px;line-height:normal;padding:15px 23px 14px;text-decoration:none;top:5px;width:auto;z-index:100000}
4
+
5
+ .wp-core-ui.wp-admin .wcc-root .global-notices{text-align:right;pointer-events:none;z-index:179;position:fixed;top:auto;right:0;bottom:0;left:0}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .global-notices{top:63px;right:16px;bottom:auto;left:auto;max-width:calc( 100% - 32px)}}@media (min-width: 961px){.wp-core-ui.wp-admin .wcc-root .global-notices{top:71px;right:24px;max-width:calc( 100% - 48px)}}@media (min-width: 1041px){.wp-core-ui.wp-admin .wcc-root .global-notices{right:32px;max-width:calc( 100% - 64px)}}.wp-core-ui.wp-admin .wcc-root .global-notices .notice{flex-wrap:nowrap;margin-bottom:0;text-align:left;pointer-events:auto;border-radius:0;box-shadow:0 2px 5px rgba(0,0,0,0.2),0 0 56px rgba(0,0,0,0.15)}.wp-core-ui.wp-admin .wcc-root .global-notices .notice .notice__icon-wrapper{border-radius:0}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .global-notices .notice{display:flex;overflow:hidden;margin-bottom:24px;border-radius:3px}.wp-core-ui.wp-admin .wcc-root .global-notices .notice .notice__icon-wrapper{border-radius:3px 0 0 3px}}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .global-notices .notice a.notice__action{font-size:14px;padding:13px 16px}}.wp-core-ui.wp-admin .wcc-root .global-notices .notice__dismiss{flex-shrink:0}@media (min-width: 661px){.wp-core-ui.wp-admin .wcc-root .global-notices .notice__dismiss{padding:13px 16px 0}}
6
+
7
+ .wp-core-ui.wp-admin .wcc-root .token-field{margin:0;padding:7px 14px;width:100%;color:var(--color-neutral-700);font-size:16px;line-height:1.5;border:1px solid var(--color-neutral-100);background-color:var(--color-white);transition:all 0.15s ease-in-out;box-sizing:border-box}.wp-core-ui.wp-admin .wcc-root .token-field:-ms-input-placeholder{color:var(--color-neutral-500)}.wp-core-ui.wp-admin .wcc-root .token-field::placeholder{color:var(--color-neutral-500)}.wp-core-ui.wp-admin .wcc-root .token-field:hover{border-color:var(--color-neutral-200)}.wp-core-ui.wp-admin .wcc-root .token-field:focus{border-color:var(--color-primary);outline:none;box-shadow:0 0 0 2px var(--color-primary-100)}.wp-core-ui.wp-admin .wcc-root .token-field:focus:hover{box-shadow:0 0 0 2px var(--color-primary-200)}.wp-core-ui.wp-admin .wcc-root .token-field:focus::-ms-clear{display:none}.wp-core-ui.wp-admin .wcc-root .token-field:disabled{background:var(--color-neutral-0);border-color:var(--color-neutral-0);color:var(--color-neutral-200);opacity:1;-webkit-text-fill-color:var(--color-neutral-200)}.wp-core-ui.wp-admin .wcc-root .token-field:disabled:hover{cursor:default}.wp-core-ui.wp-admin .wcc-root .token-field:disabled:-ms-input-placeholder{color:var(--color-neutral-200)}.wp-core-ui.wp-admin .wcc-root .token-field:disabled::placeholder{color:var(--color-neutral-200)}.wp-core-ui.wp-admin .wcc-root .is-valid.token-field{border-color:var(--color-success)}.wp-core-ui.wp-admin .wcc-root .is-valid.token-field:hover{border-color:var(--color-success-dark)}.wp-core-ui.wp-admin .wcc-root .is-error.token-field{border-color:var(--color-error)}.wp-core-ui.wp-admin .wcc-root .is-error.token-field:hover{border-color:var(--color-error-dark)}.wp-core-ui.wp-admin .wcc-root .token-field:focus.is-valid{box-shadow:0 0 0 2px var(--color-success-100)}.wp-core-ui.wp-admin .wcc-root .token-field:focus.is-valid:hover{box-shadow:0 0 0 2px var(--color-success-200)}.wp-core-ui.wp-admin .wcc-root .token-field:focus.is-error{box-shadow:0 0 0 2px var(--color-error-100)}.wp-core-ui.wp-admin .wcc-root .token-field:focus.is-error:hover{box-shadow:0 0 0 2px var(--color-error-200)}.wp-core-ui.wp-admin .wcc-root .token-field{box-sizing:border-box;width:100%;margin:0;padding:0;background-color:var(--color-white);border:1px solid var(--color-neutral-100);color:var(--color-neutral-700);cursor:text;transition:all 0.15s ease-in-out}.wp-core-ui.wp-admin .wcc-root .token-field:hover{border-color:var(--color-neutral-200)}.wp-core-ui.wp-admin .wcc-root .token-field.is-disabled{background:var(--color-neutral-0);border-color:var(--color-neutral-0)}.wp-core-ui.wp-admin .wcc-root .token-field.is-active{border-color:var(--color-primary);box-shadow:0 0 0 2px var(--color-primary-light)}.wp-core-ui.wp-admin .wcc-root .token-field__input-container{display:flex;flex-wrap:wrap;align-items:flex-start;padding:5px 14px 5px 0}.wp-core-ui.wp-admin .wcc-root input[type='text'].token-field__input{display:inline-block;width:auto;max-width:100%;margin:2px 0 2px 8px;padding:0 0 0 6px;line-height:24px;background:inherit;border:0;outline:none;font-family:inherit;font-size:14px;color:var(--color-neutral-700)}.wp-core-ui.wp-admin .wcc-root input[type='text'].token-field__input:focus{box-shadow:none}.wp-core-ui.wp-admin .wcc-root .token-field__token{font-size:14px;display:flex;margin:2px 0 2px 8px;color:var(--color-white);overflow:hidden}.wp-core-ui.wp-admin .wcc-root .token-field__token.is-success .token-field__token-text,.wp-core-ui.wp-admin .wcc-root .token-field__token.is-success .token-field__remove-token{background:var(--color-success)}.wp-core-ui.wp-admin .wcc-root .token-field__token.is-error .token-field__token-text,.wp-core-ui.wp-admin .wcc-root .token-field__token.is-error .token-field__remove-token{background:var(--color-error)}.wp-core-ui.wp-admin .wcc-root .token-field__token.is-validating .token-field__token-text,.wp-core-ui.wp-admin .wcc-root .token-field__token.is-validating .token-field__remove-token{background:var(--color-neutral-light)}.wp-core-ui.wp-admin .wcc-root .token-field__token.is-borderless{position:relative;padding:0 16px 0 0}.wp-core-ui.wp-admin .wcc-root .token-field__token.is-borderless .token-field__token-text{background:transparent;color:var(--color-primary)}.wp-core-ui.wp-admin .wcc-root .token-field__token.is-borderless .token-field__remove-token{background:transparent;color:var(--color-neutral-light);position:absolute;top:1px;right:0}.wp-core-ui.wp-admin .wcc-root .token-field__token.is-borderless.is-success .token-field__token-text{color:var(--color-success)}.wp-core-ui.wp-admin .wcc-root .token-field__token.is-borderless.is-error .token-field__token-text{color:var(--color-error);border-radius:4px 0 0 4px;padding:0 4px 0 6px}.wp-core-ui.wp-admin .wcc-root .token-field__token.is-borderless.is-validating .token-field__token-text{color:var(--color-neutral-700)}.wp-core-ui.wp-admin .wcc-root .token-field__token.is-disabled .token-field__remove-token{cursor:default}.wp-core-ui.wp-admin .wcc-root .token-field__token-text,.wp-core-ui.wp-admin .wcc-root .token-field__remove-token{display:inline-block;line-height:24px;background:var(--color-neutral-500);transition:all 0.2s cubic-bezier(0.4, 1, 0.4, 1)}.wp-core-ui.wp-admin .wcc-root .token-field__token-text{border-radius:4px 0 0 4px;padding:0 4px 0 6px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.wp-core-ui.wp-admin .wcc-root .token-field__remove-token{cursor:pointer;border-radius:0 4px 4px 0;color:var(--color-neutral-100)}.wp-core-ui.wp-admin .wcc-root .token-field__remove-token:hover{color:white;background:var(--color-neutral-400)}.wp-core-ui.wp-admin .wcc-root .token-field__suggestions-list{background:var(--color-white);max-height:0;overflow-y:scroll;transition:all 0.15s ease-in-out;list-style:none;margin:0}.wp-core-ui.wp-admin .wcc-root .token-field__suggestions-list.is-expanded{background:var(--color-white);border-top:1px solid var(--color-neutral-100);max-height:9em;padding-top:3px}.wp-core-ui.wp-admin .wcc-root .token-field__suggestion{color:var(--color-neutral-light);display:block;font-size:13px;padding:4px 8px;cursor:pointer}.wp-core-ui.wp-admin .wcc-root .token-field__suggestion.is-selected{background:var(--color-accent);color:var(--color-white)}.wp-core-ui.wp-admin .wcc-root .token-field__suggestion-match{color:var(--color-neutral-700)}
8
+
9
+ .wp-core-ui.wp-admin .wcc-root .external-link .gridicons-external{color:currentColor;margin-left:3px;margin-right:0;top:2px;position:relative}.wp-core-ui.wp-admin .wcc-root .external-link:hover{cursor:pointer}.wp-core-ui.wp-admin .wcc-root .icon-first .gridicons-external{margin-left:0;margin-right:3px}
10
+
11
+ @keyframes rotate-spinner{100%{transform:rotate(360deg)}}.wp-core-ui.wp-admin .wcc-root .spinner{display:flex;align-items:center}.wp-core-ui.wp-admin .wcc-root .spinner__outer,.wp-core-ui.wp-admin .wcc-root .spinner__inner{margin:auto;box-sizing:border-box;border:0.1em solid transparent;border-radius:50%;animation:3s linear infinite;animation-name:rotate-spinner}.wp-core-ui.wp-admin .wcc-root .spinner__outer{border-top-color:var(--color-accent)}.wp-core-ui.wp-admin .wcc-root .spinner__inner{width:100%;height:100%;border-top-color:var(--color-accent);border-right-color:var(--color-accent);opacity:0.4}
12
+
13
+ .wp-core-ui.wp-admin .wcc-root .purchase-section{text-align:center}.wp-core-ui.wp-admin .wcc-root .purchase-section__explanation{padding-top:15px;font-size:12px;color:gray}
14
+
15
+ .wp-core-ui.wp-admin .wcc-root .gridicon.ellipsis-menu__toggle-icon{transition:transform 0.15s cubic-bezier(0.175, 0.885, 0.32, 1.275)}.wp-core-ui.wp-admin .wcc-root .ellipsis-menu.is-menu-visible .gridicon.ellipsis-menu__toggle-icon{transform:rotate(90deg)}
16
+
17
+ .wp-core-ui.wp-admin .wcc-root .count{display:inline-block;padding:1px 6px;border:solid 1px var(--color-border);border-radius:12px;font-size:11px;font-weight:600;line-height:14px;color:var(--color-text);text-align:center}.wp-core-ui.wp-admin .wcc-root .count.is-primary{color:var(--color-white);border-color:var(--color-accent);background-color:var(--color-accent)}
18
+
19
+ .wp-core-ui.wp-admin .wcc-root .section-header.card{display:flex;align-items:center;padding-top:11px;padding-bottom:11px;position:relative;line-height:28px}.wp-core-ui.wp-admin .wcc-root .section-header.card::after{content:''}.wp-core-ui.wp-admin .wcc-root .section-header.card.is-empty .section-header__label::after{content:'\A0'}.wp-core-ui.wp-admin .wcc-root .section-header__label{display:flex;align-items:center;flex-grow:1;position:relative;overflow:hidden}.wp-core-ui.wp-admin .wcc-root .section-header__label::before{content:'';display:block;position:absolute;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none;background:linear-gradient(to right, rgba( 255,255,255 , 0 ), rgba( 255,255,255 , 1 ) 90%);top:0;bottom:0;right:0;left:auto;width:20%;height:auto}.wp-core-ui.wp-admin .wcc-root .section-header__label .count{margin-left:8px}.wp-core-ui.wp-admin .wcc-root .section-header__actions{flex-grow:0;position:relative}.wp-core-ui.wp-admin .wcc-root .section-header__actions::after{content:'.';display:block;height:0;width:0;clear:both;visibility:hidden;overflow:hidden}.wp-core-ui.wp-admin .wcc-root .section-header__label{color:var(--color-neutral-700);font-size:14px}.wp-core-ui.wp-admin .wcc-root .section-header__actions .button{float:left;margin-right:8px}.wp-core-ui.wp-admin .wcc-root .section-header__actions>.button:last-child{margin-right:0}
20
+
trunk/dist/woocommerce-services-1.22.4.js ADDED
@@ -0,0 +1,107 @@
 
 
 
 
 
 
 
1
+ !function(e){var t={};function n(r){if(t[r])return t[r].exports;var a=t[r]={i:r,l:!1,exports:{}};return e[r].call(a.exports,a,a.exports,n),a.l=!0,a.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)n.d(r,a,function(t){return e[t]}.bind(null,a));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="http://localhost:8085/",n(n.s=455)}([function(e,t,n){"use strict";e.exports=n(617)},function(e,t,n){(function(e){(function(){var n,r=200,a="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",o="Expected a function",i="__lodash_hash_undefined__",s=500,c="__lodash_placeholder__",u=1,l=2,d=4,f=1,p=2,h=1,m=2,v=4,b=8,g=16,y=32,_=64,M=128,E=256,O=512,w=30,k="...",L=800,S=16,A=1,T=2,z=1/0,C=9007199254740991,D=1.7976931348623157e308,N=NaN,P=4294967295,x=P-1,I=P>>>1,R=[["ary",M],["bind",h],["bindKey",m],["curry",b],["curryRight",g],["flip",O],["partial",y],["partialRight",_],["rearg",E]],j="[object Arguments]",H="[object Array]",W="[object AsyncFunction]",Y="[object Boolean]",q="[object Date]",B="[object DOMException]",F="[object Error]",V="[object Function]",X="[object GeneratorFunction]",U="[object Map]",G="[object Number]",K="[object Null]",J="[object Object]",$="[object Proxy]",Q="[object RegExp]",Z="[object Set]",ee="[object String]",te="[object Symbol]",ne="[object Undefined]",re="[object WeakMap]",ae="[object WeakSet]",oe="[object ArrayBuffer]",ie="[object DataView]",se="[object Float32Array]",ce="[object Float64Array]",ue="[object Int8Array]",le="[object Int16Array]",de="[object Int32Array]",fe="[object Uint8Array]",pe="[object Uint8ClampedArray]",he="[object Uint16Array]",me="[object Uint32Array]",ve=/\b__p \+= '';/g,be=/\b(__p \+=) '' \+/g,ge=/(__e\(.*?\)|\b__t\)) \+\n'';/g,ye=/&(?:amp|lt|gt|quot|#39);/g,_e=/[&<>"']/g,Me=RegExp(ye.source),Ee=RegExp(_e.source),Oe=/<%-([\s\S]+?)%>/g,we=/<%([\s\S]+?)%>/g,ke=/<%=([\s\S]+?)%>/g,Le=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Se=/^\w*$/,Ae=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Te=/[\\^$.*+?()[\]{}|]/g,ze=RegExp(Te.source),Ce=/^\s+|\s+$/g,De=/^\s+/,Ne=/\s+$/,Pe=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,xe=/\{\n\/\* \[wrapped with (.+)\] \*/,Ie=/,? & /,Re=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,je=/\\(\\)?/g,He=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,We=/\w*$/,Ye=/^[-+]0x[0-9a-f]+$/i,qe=/^0b[01]+$/i,Be=/^\[object .+?Constructor\]$/,Fe=/^0o[0-7]+$/i,Ve=/^(?:0|[1-9]\d*)$/,Xe=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Ue=/($^)/,Ge=/['\n\r\u2028\u2029\\]/g,Ke="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Je="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",$e="[\\ud800-\\udfff]",Qe="["+Je+"]",Ze="["+Ke+"]",et="\\d+",tt="[\\u2700-\\u27bf]",nt="[a-z\\xdf-\\xf6\\xf8-\\xff]",rt="[^\\ud800-\\udfff"+Je+et+"\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde]",at="\\ud83c[\\udffb-\\udfff]",ot="[^\\ud800-\\udfff]",it="(?:\\ud83c[\\udde6-\\uddff]){2}",st="[\\ud800-\\udbff][\\udc00-\\udfff]",ct="[A-Z\\xc0-\\xd6\\xd8-\\xde]",ut="(?:"+nt+"|"+rt+")",lt="(?:"+ct+"|"+rt+")",dt="(?:"+Ze+"|"+at+")"+"?",ft="[\\ufe0e\\ufe0f]?"+dt+("(?:\\u200d(?:"+[ot,it,st].join("|")+")[\\ufe0e\\ufe0f]?"+dt+")*"),pt="(?:"+[tt,it,st].join("|")+")"+ft,ht="(?:"+[ot+Ze+"?",Ze,it,st,$e].join("|")+")",mt=RegExp("['’]","g"),vt=RegExp(Ze,"g"),bt=RegExp(at+"(?="+at+")|"+ht+ft,"g"),gt=RegExp([ct+"?"+nt+"+(?:['’](?:d|ll|m|re|s|t|ve))?(?="+[Qe,ct,"$"].join("|")+")",lt+"+(?:['’](?:D|LL|M|RE|S|T|VE))?(?="+[Qe,ct+ut,"$"].join("|")+")",ct+"?"+ut+"+(?:['’](?:d|ll|m|re|s|t|ve))?",ct+"+(?:['’](?:D|LL|M|RE|S|T|VE))?","\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",et,pt].join("|"),"g"),yt=RegExp("[\\u200d\\ud800-\\udfff"+Ke+"\\ufe0e\\ufe0f]"),_t=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Mt=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Et=-1,Ot={};Ot[se]=Ot[ce]=Ot[ue]=Ot[le]=Ot[de]=Ot[fe]=Ot[pe]=Ot[he]=Ot[me]=!0,Ot[j]=Ot[H]=Ot[oe]=Ot[Y]=Ot[ie]=Ot[q]=Ot[F]=Ot[V]=Ot[U]=Ot[G]=Ot[J]=Ot[Q]=Ot[Z]=Ot[ee]=Ot[re]=!1;var wt={};wt[j]=wt[H]=wt[oe]=wt[ie]=wt[Y]=wt[q]=wt[se]=wt[ce]=wt[ue]=wt[le]=wt[de]=wt[U]=wt[G]=wt[J]=wt[Q]=wt[Z]=wt[ee]=wt[te]=wt[fe]=wt[pe]=wt[he]=wt[me]=!0,wt[F]=wt[V]=wt[re]=!1;var kt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Lt=parseFloat,St=parseInt,At=window&&window.Object===Object&&window,Tt="object"==typeof self&&self&&self.Object===Object&&self,zt=At||Tt||Function("return this")(),Ct="object"==typeof t&&t&&!t.nodeType&&t,Dt=Ct&&"object"==typeof e&&e&&!e.nodeType&&e,Nt=Dt&&Dt.exports===Ct,Pt=Nt&&At.process,xt=function(){try{var e=Dt&&Dt.require&&Dt.require("util").types;return e||Pt&&Pt.binding&&Pt.binding("util")}catch(t){}}(),It=xt&&xt.isArrayBuffer,Rt=xt&&xt.isDate,jt=xt&&xt.isMap,Ht=xt&&xt.isRegExp,Wt=xt&&xt.isSet,Yt=xt&&xt.isTypedArray;function qt(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function Bt(e,t,n,r){for(var a=-1,o=null==e?0:e.length;++a<o;){var i=e[a];t(r,i,n(i),e)}return r}function Ft(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}function Vt(e,t){for(var n=null==e?0:e.length;n--&&!1!==t(e[n],n,e););return e}function Xt(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}function Ut(e,t){for(var n=-1,r=null==e?0:e.length,a=0,o=[];++n<r;){var i=e[n];t(i,n,e)&&(o[a++]=i)}return o}function Gt(e,t){return!!(null==e?0:e.length)&&an(e,t,0)>-1}function Kt(e,t,n){for(var r=-1,a=null==e?0:e.length;++r<a;)if(n(t,e[r]))return!0;return!1}function Jt(e,t){for(var n=-1,r=null==e?0:e.length,a=Array(r);++n<r;)a[n]=t(e[n],n,e);return a}function $t(e,t){for(var n=-1,r=t.length,a=e.length;++n<r;)e[a+n]=t[n];return e}function Qt(e,t,n,r){var a=-1,o=null==e?0:e.length;for(r&&o&&(n=e[++a]);++a<o;)n=t(n,e[a],a,e);return n}function Zt(e,t,n,r){var a=null==e?0:e.length;for(r&&a&&(n=e[--a]);a--;)n=t(n,e[a],a,e);return n}function en(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}var tn=un("length");function nn(e,t,n){var r;return n(e,function(e,n,a){if(t(e,n,a))return r=n,!1}),r}function rn(e,t,n,r){for(var a=e.length,o=n+(r?1:-1);r?o--:++o<a;)if(t(e[o],o,e))return o;return-1}function an(e,t,n){return t==t?function(e,t,n){var r=n-1,a=e.length;for(;++r<a;)if(e[r]===t)return r;return-1}(e,t,n):rn(e,sn,n)}function on(e,t,n,r){for(var a=n-1,o=e.length;++a<o;)if(r(e[a],t))return a;return-1}function sn(e){return e!=e}function cn(e,t){var n=null==e?0:e.length;return n?fn(e,t)/n:N}function un(e){return function(t){return null==t?n:t[e]}}function ln(e){return function(t){return null==e?n:e[t]}}function dn(e,t,n,r,a){return a(e,function(e,a,o){n=r?(r=!1,e):t(n,e,a,o)}),n}function fn(e,t){for(var r,a=-1,o=e.length;++a<o;){var i=t(e[a]);i!==n&&(r=r===n?i:r+i)}return r}function pn(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function hn(e){return function(t){return e(t)}}function mn(e,t){return Jt(t,function(t){return e[t]})}function vn(e,t){return e.has(t)}function bn(e,t){for(var n=-1,r=e.length;++n<r&&an(t,e[n],0)>-1;);return n}function gn(e,t){for(var n=e.length;n--&&an(t,e[n],0)>-1;);return n}var yn=ln({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"}),_n=ln({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"});function Mn(e){return"\\"+kt[e]}function En(e){return yt.test(e)}function On(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function wn(e,t){return function(n){return e(t(n))}}function kn(e,t){for(var n=-1,r=e.length,a=0,o=[];++n<r;){var i=e[n];i!==t&&i!==c||(e[n]=c,o[a++]=n)}return o}function Ln(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}function Sn(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=[e,e]}),n}function An(e){return En(e)?function(e){var t=bt.lastIndex=0;for(;bt.test(e);)++t;return t}(e):tn(e)}function Tn(e){return En(e)?function(e){return e.match(bt)||[]}(e):function(e){return e.split("")}(e)}var zn=ln({"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"});var Cn=function e(t){var Ke,Je=(t=null==t?zt:Cn.defaults(zt.Object(),t,Cn.pick(zt,Mt))).Array,$e=t.Date,Qe=t.Error,Ze=t.Function,et=t.Math,tt=t.Object,nt=t.RegExp,rt=t.String,at=t.TypeError,ot=Je.prototype,it=Ze.prototype,st=tt.prototype,ct=t["__core-js_shared__"],ut=it.toString,lt=st.hasOwnProperty,dt=0,ft=(Ke=/[^.]+$/.exec(ct&&ct.keys&&ct.keys.IE_PROTO||""))?"Symbol(src)_1."+Ke:"",pt=st.toString,ht=ut.call(tt),bt=zt._,yt=nt("^"+ut.call(lt).replace(Te,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),kt=Nt?t.Buffer:n,At=t.Symbol,Tt=t.Uint8Array,Ct=kt?kt.allocUnsafe:n,Dt=wn(tt.getPrototypeOf,tt),Pt=tt.create,xt=st.propertyIsEnumerable,tn=ot.splice,ln=At?At.isConcatSpreadable:n,Dn=At?At.iterator:n,Nn=At?At.toStringTag:n,Pn=function(){try{var e=Ho(tt,"defineProperty");return e({},"",{}),e}catch(t){}}(),xn=t.clearTimeout!==zt.clearTimeout&&t.clearTimeout,In=$e&&$e.now!==zt.Date.now&&$e.now,Rn=t.setTimeout!==zt.setTimeout&&t.setTimeout,jn=et.ceil,Hn=et.floor,Wn=tt.getOwnPropertySymbols,Yn=kt?kt.isBuffer:n,qn=t.isFinite,Bn=ot.join,Fn=wn(tt.keys,tt),Vn=et.max,Xn=et.min,Un=$e.now,Gn=t.parseInt,Kn=et.random,Jn=ot.reverse,$n=Ho(t,"DataView"),Qn=Ho(t,"Map"),Zn=Ho(t,"Promise"),er=Ho(t,"Set"),tr=Ho(t,"WeakMap"),nr=Ho(tt,"create"),rr=tr&&new tr,ar={},or=di($n),ir=di(Qn),sr=di(Zn),cr=di(er),ur=di(tr),lr=At?At.prototype:n,dr=lr?lr.valueOf:n,fr=lr?lr.toString:n;function pr(e){if(As(e)&&!bs(e)&&!(e instanceof br)){if(e instanceof vr)return e;if(lt.call(e,"__wrapped__"))return fi(e)}return new vr(e)}var hr=function(){function e(){}return function(t){if(!Ss(t))return{};if(Pt)return Pt(t);e.prototype=t;var r=new e;return e.prototype=n,r}}();function mr(){}function vr(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=n}function br(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=P,this.__views__=[]}function gr(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function yr(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function _r(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Mr(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new _r;++t<n;)this.add(e[t])}function Er(e){var t=this.__data__=new yr(e);this.size=t.size}function Or(e,t){var n=bs(e),r=!n&&vs(e),a=!n&&!r&&Ms(e),o=!n&&!r&&!a&&Is(e),i=n||r||a||o,s=i?pn(e.length,rt):[],c=s.length;for(var u in e)!t&&!lt.call(e,u)||i&&("length"==u||a&&("offset"==u||"parent"==u)||o&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||Xo(u,c))||s.push(u);return s}function wr(e){var t=e.length;return t?e[Ma(0,t-1)]:n}function kr(e,t){return ci(no(e),Pr(t,0,e.length))}function Lr(e){return ci(no(e))}function Sr(e,t,r){(r===n||ps(e[t],r))&&(r!==n||t in e)||Dr(e,t,r)}function Ar(e,t,r){var a=e[t];lt.call(e,t)&&ps(a,r)&&(r!==n||t in e)||Dr(e,t,r)}function Tr(e,t){for(var n=e.length;n--;)if(ps(e[n][0],t))return n;return-1}function zr(e,t,n,r){return Hr(e,function(e,a,o){t(r,e,n(e),o)}),r}function Cr(e,t){return e&&ro(t,ac(t),e)}function Dr(e,t,n){"__proto__"==t&&Pn?Pn(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function Nr(e,t){for(var r=-1,a=t.length,o=Je(a),i=null==e;++r<a;)o[r]=i?n:Zs(e,t[r]);return o}function Pr(e,t,r){return e==e&&(r!==n&&(e=e<=r?e:r),t!==n&&(e=e>=t?e:t)),e}function xr(e,t,r,a,o,i){var s,c=t&u,f=t&l,p=t&d;if(r&&(s=o?r(e,a,o,i):r(e)),s!==n)return s;if(!Ss(e))return e;var h=bs(e);if(h){if(s=function(e){var t=e.length,n=new e.constructor(t);return t&&"string"==typeof e[0]&&lt.call(e,"index")&&(n.index=e.index,n.input=e.input),n}(e),!c)return no(e,s)}else{var m=qo(e),v=m==V||m==X;if(Ms(e))return Ja(e,c);if(m==J||m==j||v&&!o){if(s=f||v?{}:Fo(e),!c)return f?function(e,t){return ro(e,Yo(e),t)}(e,function(e,t){return e&&ro(t,oc(t),e)}(s,e)):function(e,t){return ro(e,Wo(e),t)}(e,Cr(s,e))}else{if(!wt[m])return o?e:{};s=function(e,t,n){var r,a,o,i=e.constructor;switch(t){case oe:return $a(e);case Y:case q:return new i(+e);case ie:return function(e,t){var n=t?$a(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}(e,n);case se:case ce:case ue:case le:case de:case fe:case pe:case he:case me:return Qa(e,n);case U:return new i;case G:case ee:return new i(e);case Q:return(o=new(a=e).constructor(a.source,We.exec(a))).lastIndex=a.lastIndex,o;case Z:return new i;case te:return r=e,dr?tt(dr.call(r)):{}}}(e,m,c)}}i||(i=new Er);var b=i.get(e);if(b)return b;i.set(e,s),Ns(e)?e.forEach(function(n){s.add(xr(n,t,r,n,e,i))}):Ts(e)&&e.forEach(function(n,a){s.set(a,xr(n,t,r,a,e,i))});var g=h?n:(p?f?Do:Co:f?oc:ac)(e);return Ft(g||e,function(n,a){g&&(n=e[a=n]),Ar(s,a,xr(n,t,r,a,e,i))}),s}function Ir(e,t,r){var a=r.length;if(null==e)return!a;for(e=tt(e);a--;){var o=r[a],i=t[o],s=e[o];if(s===n&&!(o in e)||!i(s))return!1}return!0}function Rr(e,t,r){if("function"!=typeof e)throw new at(o);return ai(function(){e.apply(n,r)},t)}function jr(e,t,n,a){var o=-1,i=Gt,s=!0,c=e.length,u=[],l=t.length;if(!c)return u;n&&(t=Jt(t,hn(n))),a?(i=Kt,s=!1):t.length>=r&&(i=vn,s=!1,t=new Mr(t));e:for(;++o<c;){var d=e[o],f=null==n?d:n(d);if(d=a||0!==d?d:0,s&&f==f){for(var p=l;p--;)if(t[p]===f)continue e;u.push(d)}else i(t,f,a)||u.push(d)}return u}pr.templateSettings={escape:Oe,evaluate:we,interpolate:ke,variable:"",imports:{_:pr}},pr.prototype=mr.prototype,pr.prototype.constructor=pr,vr.prototype=hr(mr.prototype),vr.prototype.constructor=vr,br.prototype=hr(mr.prototype),br.prototype.constructor=br,gr.prototype.clear=function(){this.__data__=nr?nr(null):{},this.size=0},gr.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},gr.prototype.get=function(e){var t=this.__data__;if(nr){var r=t[e];return r===i?n:r}return lt.call(t,e)?t[e]:n},gr.prototype.has=function(e){var t=this.__data__;return nr?t[e]!==n:lt.call(t,e)},gr.prototype.set=function(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=nr&&t===n?i:t,this},yr.prototype.clear=function(){this.__data__=[],this.size=0},yr.prototype.delete=function(e){var t=this.__data__,n=Tr(t,e);return!(n<0||(n==t.length-1?t.pop():tn.call(t,n,1),--this.size,0))},yr.prototype.get=function(e){var t=this.__data__,r=Tr(t,e);return r<0?n:t[r][1]},yr.prototype.has=function(e){return Tr(this.__data__,e)>-1},yr.prototype.set=function(e,t){var n=this.__data__,r=Tr(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this},_r.prototype.clear=function(){this.size=0,this.__data__={hash:new gr,map:new(Qn||yr),string:new gr}},_r.prototype.delete=function(e){var t=Ro(this,e).delete(e);return this.size-=t?1:0,t},_r.prototype.get=function(e){return Ro(this,e).get(e)},_r.prototype.has=function(e){return Ro(this,e).has(e)},_r.prototype.set=function(e,t){var n=Ro(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this},Mr.prototype.add=Mr.prototype.push=function(e){return this.__data__.set(e,i),this},Mr.prototype.has=function(e){return this.__data__.has(e)},Er.prototype.clear=function(){this.__data__=new yr,this.size=0},Er.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},Er.prototype.get=function(e){return this.__data__.get(e)},Er.prototype.has=function(e){return this.__data__.has(e)},Er.prototype.set=function(e,t){var n=this.__data__;if(n instanceof yr){var a=n.__data__;if(!Qn||a.length<r-1)return a.push([e,t]),this.size=++n.size,this;n=this.__data__=new _r(a)}return n.set(e,t),this.size=n.size,this};var Hr=io(Ur),Wr=io(Gr,!0);function Yr(e,t){var n=!0;return Hr(e,function(e,r,a){return n=!!t(e,r,a)}),n}function qr(e,t,r){for(var a=-1,o=e.length;++a<o;){var i=e[a],s=t(i);if(null!=s&&(c===n?s==s&&!xs(s):r(s,c)))var c=s,u=i}return u}function Br(e,t){var n=[];return Hr(e,function(e,r,a){t(e,r,a)&&n.push(e)}),n}function Fr(e,t,n,r,a){var o=-1,i=e.length;for(n||(n=Vo),a||(a=[]);++o<i;){var s=e[o];t>0&&n(s)?t>1?Fr(s,t-1,n,r,a):$t(a,s):r||(a[a.length]=s)}return a}var Vr=so(),Xr=so(!0);function Ur(e,t){return e&&Vr(e,t,ac)}function Gr(e,t){return e&&Xr(e,t,ac)}function Kr(e,t){return Ut(t,function(t){return ws(e[t])})}function Jr(e,t){for(var r=0,a=(t=Xa(t,e)).length;null!=e&&r<a;)e=e[li(t[r++])];return r&&r==a?e:n}function $r(e,t,n){var r=t(e);return bs(e)?r:$t(r,n(e))}function Qr(e){return null==e?e===n?ne:K:Nn&&Nn in tt(e)?function(e){var t=lt.call(e,Nn),r=e[Nn];try{e[Nn]=n;var a=!0}catch(i){}var o=pt.call(e);return a&&(t?e[Nn]=r:delete e[Nn]),o}(e):function(e){return pt.call(e)}(e)}function Zr(e,t){return e>t}function ea(e,t){return null!=e&&lt.call(e,t)}function ta(e,t){return null!=e&&t in tt(e)}function na(e,t,r){for(var a=r?Kt:Gt,o=e[0].length,i=e.length,s=i,c=Je(i),u=1/0,l=[];s--;){var d=e[s];s&&t&&(d=Jt(d,hn(t))),u=Xn(d.length,u),c[s]=!r&&(t||o>=120&&d.length>=120)?new Mr(s&&d):n}d=e[0];var f=-1,p=c[0];e:for(;++f<o&&l.length<u;){var h=d[f],m=t?t(h):h;if(h=r||0!==h?h:0,!(p?vn(p,m):a(l,m,r))){for(s=i;--s;){var v=c[s];if(!(v?vn(v,m):a(e[s],m,r)))continue e}p&&p.push(m),l.push(h)}}return l}function ra(e,t,r){var a=null==(e=ti(e,t=Xa(t,e)))?e:e[li(Oi(t))];return null==a?n:qt(a,e,r)}function aa(e){return As(e)&&Qr(e)==j}function oa(e,t,r,a,o){return e===t||(null==e||null==t||!As(e)&&!As(t)?e!=e&&t!=t:function(e,t,r,a,o,i){var s=bs(e),c=bs(t),u=s?H:qo(e),l=c?H:qo(t),d=(u=u==j?J:u)==J,h=(l=l==j?J:l)==J,m=u==l;if(m&&Ms(e)){if(!Ms(t))return!1;s=!0,d=!1}if(m&&!d)return i||(i=new Er),s||Is(e)?To(e,t,r,a,o,i):function(e,t,n,r,a,o,i){switch(n){case ie:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case oe:return!(e.byteLength!=t.byteLength||!o(new Tt(e),new Tt(t)));case Y:case q:case G:return ps(+e,+t);case F:return e.name==t.name&&e.message==t.message;case Q:case ee:return e==t+"";case U:var s=On;case Z:var c=r&f;if(s||(s=Ln),e.size!=t.size&&!c)return!1;var u=i.get(e);if(u)return u==t;r|=p,i.set(e,t);var l=To(s(e),s(t),r,a,o,i);return i.delete(e),l;case te:if(dr)return dr.call(e)==dr.call(t)}return!1}(e,t,u,r,a,o,i);if(!(r&f)){var v=d&&lt.call(e,"__wrapped__"),b=h&&lt.call(t,"__wrapped__");if(v||b){var g=v?e.value():e,y=b?t.value():t;return i||(i=new Er),o(g,y,r,a,i)}}return!!m&&(i||(i=new Er),function(e,t,r,a,o,i){var s=r&f,c=Co(e),u=c.length,l=Co(t).length;if(u!=l&&!s)return!1;for(var d=u;d--;){var p=c[d];if(!(s?p in t:lt.call(t,p)))return!1}var h=i.get(e);if(h&&i.get(t))return h==t;var m=!0;i.set(e,t),i.set(t,e);for(var v=s;++d<u;){p=c[d];var b=e[p],g=t[p];if(a)var y=s?a(g,b,p,t,e,i):a(b,g,p,e,t,i);if(!(y===n?b===g||o(b,g,r,a,i):y)){m=!1;break}v||(v="constructor"==p)}if(m&&!v){var _=e.constructor,M=t.constructor;_!=M&&"constructor"in e&&"constructor"in t&&!("function"==typeof _&&_ instanceof _&&"function"==typeof M&&M instanceof M)&&(m=!1)}return i.delete(e),i.delete(t),m}(e,t,r,a,o,i))}(e,t,r,a,oa,o))}function ia(e,t,r,a){var o=r.length,i=o,s=!a;if(null==e)return!i;for(e=tt(e);o--;){var c=r[o];if(s&&c[2]?c[1]!==e[c[0]]:!(c[0]in e))return!1}for(;++o<i;){var u=(c=r[o])[0],l=e[u],d=c[1];if(s&&c[2]){if(l===n&&!(u in e))return!1}else{var h=new Er;if(a)var m=a(l,d,u,e,t,h);if(!(m===n?oa(d,l,f|p,a,h):m))return!1}}return!0}function sa(e){return!(!Ss(e)||(t=e,ft&&ft in t))&&(ws(e)?yt:Be).test(di(e));var t}function ca(e){return"function"==typeof e?e:null==e?zc:"object"==typeof e?bs(e)?ha(e[0],e[1]):pa(e):Hc(e)}function ua(e){if(!$o(e))return Fn(e);var t=[];for(var n in tt(e))lt.call(e,n)&&"constructor"!=n&&t.push(n);return t}function la(e){if(!Ss(e))return function(e){var t=[];if(null!=e)for(var n in tt(e))t.push(n);return t}(e);var t=$o(e),n=[];for(var r in e)("constructor"!=r||!t&&lt.call(e,r))&&n.push(r);return n}function da(e,t){return e<t}function fa(e,t){var n=-1,r=ys(e)?Je(e.length):[];return Hr(e,function(e,a,o){r[++n]=t(e,a,o)}),r}function pa(e){var t=jo(e);return 1==t.length&&t[0][2]?Zo(t[0][0],t[0][1]):function(n){return n===e||ia(n,e,t)}}function ha(e,t){return Go(e)&&Qo(t)?Zo(li(e),t):function(r){var a=Zs(r,e);return a===n&&a===t?ec(r,e):oa(t,a,f|p)}}function ma(e,t,r,a,o){e!==t&&Vr(t,function(i,s){if(o||(o=new Er),Ss(i))!function(e,t,r,a,o,i,s){var c=ni(e,r),u=ni(t,r),l=s.get(u);if(l)Sr(e,r,l);else{var d=i?i(c,u,r+"",e,t,s):n,f=d===n;if(f){var p=bs(u),h=!p&&Ms(u),m=!p&&!h&&Is(u);d=u,p||h||m?bs(c)?d=c:_s(c)?d=no(c):h?(f=!1,d=Ja(u,!0)):m?(f=!1,d=Qa(u,!0)):d=[]:Cs(u)||vs(u)?(d=c,vs(c)?d=Fs(c):Ss(c)&&!ws(c)||(d=Fo(u))):f=!1}f&&(s.set(u,d),o(d,u,a,i,s),s.delete(u)),Sr(e,r,d)}}(e,t,s,r,ma,a,o);else{var c=a?a(ni(e,s),i,s+"",e,t,o):n;c===n&&(c=i),Sr(e,s,c)}},oc)}function va(e,t){var r=e.length;if(r)return Xo(t+=t<0?r:0,r)?e[t]:n}function ba(e,t,n){var r=-1;return t=Jt(t.length?t:[zc],hn(Io())),function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}(fa(e,function(e,n,a){return{criteria:Jt(t,function(t){return t(e)}),index:++r,value:e}}),function(e,t){return function(e,t,n){for(var r=-1,a=e.criteria,o=t.criteria,i=a.length,s=n.length;++r<i;){var c=Za(a[r],o[r]);if(c){if(r>=s)return c;var u=n[r];return c*("desc"==u?-1:1)}}return e.index-t.index}(e,t,n)})}function ga(e,t,n){for(var r=-1,a=t.length,o={};++r<a;){var i=t[r],s=Jr(e,i);n(s,i)&&La(o,Xa(i,e),s)}return o}function ya(e,t,n,r){var a=r?on:an,o=-1,i=t.length,s=e;for(e===t&&(t=no(t)),n&&(s=Jt(e,hn(n)));++o<i;)for(var c=0,u=t[o],l=n?n(u):u;(c=a(s,l,c,r))>-1;)s!==e&&tn.call(s,c,1),tn.call(e,c,1);return e}function _a(e,t){for(var n=e?t.length:0,r=n-1;n--;){var a=t[n];if(n==r||a!==o){var o=a;Xo(a)?tn.call(e,a,1):ja(e,a)}}return e}function Ma(e,t){return e+Hn(Kn()*(t-e+1))}function Ea(e,t){var n="";if(!e||t<1||t>C)return n;do{t%2&&(n+=e),(t=Hn(t/2))&&(e+=e)}while(t);return n}function Oa(e,t){return oi(ei(e,t,zc),e+"")}function wa(e){return wr(pc(e))}function ka(e,t){var n=pc(e);return ci(n,Pr(t,0,n.length))}function La(e,t,r,a){if(!Ss(e))return e;for(var o=-1,i=(t=Xa(t,e)).length,s=i-1,c=e;null!=c&&++o<i;){var u=li(t[o]),l=r;if(o!=s){var d=c[u];(l=a?a(d,u,c):n)===n&&(l=Ss(d)?d:Xo(t[o+1])?[]:{})}Ar(c,u,l),c=c[u]}return e}var Sa=rr?function(e,t){return rr.set(e,t),e}:zc,Aa=Pn?function(e,t){return Pn(e,"toString",{configurable:!0,enumerable:!1,value:Sc(t),writable:!0})}:zc;function Ta(e){return ci(pc(e))}function za(e,t,n){var r=-1,a=e.length;t<0&&(t=-t>a?0:a+t),(n=n>a?a:n)<0&&(n+=a),a=t>n?0:n-t>>>0,t>>>=0;for(var o=Je(a);++r<a;)o[r]=e[r+t];return o}function Ca(e,t){var n;return Hr(e,function(e,r,a){return!(n=t(e,r,a))}),!!n}function Da(e,t,n){var r=0,a=null==e?r:e.length;if("number"==typeof t&&t==t&&a<=I){for(;r<a;){var o=r+a>>>1,i=e[o];null!==i&&!xs(i)&&(n?i<=t:i<t)?r=o+1:a=o}return a}return Na(e,t,zc,n)}function Na(e,t,r,a){t=r(t);for(var o=0,i=null==e?0:e.length,s=t!=t,c=null===t,u=xs(t),l=t===n;o<i;){var d=Hn((o+i)/2),f=r(e[d]),p=f!==n,h=null===f,m=f==f,v=xs(f);if(s)var b=a||m;else b=l?m&&(a||p):c?m&&p&&(a||!h):u?m&&p&&!h&&(a||!v):!h&&!v&&(a?f<=t:f<t);b?o=d+1:i=d}return Xn(i,x)}function Pa(e,t){for(var n=-1,r=e.length,a=0,o=[];++n<r;){var i=e[n],s=t?t(i):i;if(!n||!ps(s,c)){var c=s;o[a++]=0===i?0:i}}return o}function xa(e){return"number"==typeof e?e:xs(e)?N:+e}function Ia(e){if("string"==typeof e)return e;if(bs(e))return Jt(e,Ia)+"";if(xs(e))return fr?fr.call(e):"";var t=e+"";return"0"==t&&1/e==-z?"-0":t}function Ra(e,t,n){var a=-1,o=Gt,i=e.length,s=!0,c=[],u=c;if(n)s=!1,o=Kt;else if(i>=r){var l=t?null:Oo(e);if(l)return Ln(l);s=!1,o=vn,u=new Mr}else u=t?[]:c;e:for(;++a<i;){var d=e[a],f=t?t(d):d;if(d=n||0!==d?d:0,s&&f==f){for(var p=u.length;p--;)if(u[p]===f)continue e;t&&u.push(f),c.push(d)}else o(u,f,n)||(u!==c&&u.push(f),c.push(d))}return c}function ja(e,t){return null==(e=ti(e,t=Xa(t,e)))||delete e[li(Oi(t))]}function Ha(e,t,n,r){return La(e,t,n(Jr(e,t)),r)}function Wa(e,t,n,r){for(var a=e.length,o=r?a:-1;(r?o--:++o<a)&&t(e[o],o,e););return n?za(e,r?0:o,r?o+1:a):za(e,r?o+1:0,r?a:o)}function Ya(e,t){var n=e;return n instanceof br&&(n=n.value()),Qt(t,function(e,t){return t.func.apply(t.thisArg,$t([e],t.args))},n)}function qa(e,t,n){var r=e.length;if(r<2)return r?Ra(e[0]):[];for(var a=-1,o=Je(r);++a<r;)for(var i=e[a],s=-1;++s<r;)s!=a&&(o[a]=jr(o[a]||i,e[s],t,n));return Ra(Fr(o,1),t,n)}function Ba(e,t,r){for(var a=-1,o=e.length,i=t.length,s={};++a<o;){var c=a<i?t[a]:n;r(s,e[a],c)}return s}function Fa(e){return _s(e)?e:[]}function Va(e){return"function"==typeof e?e:zc}function Xa(e,t){return bs(e)?e:Go(e,t)?[e]:ui(Vs(e))}var Ua=Oa;function Ga(e,t,r){var a=e.length;return r=r===n?a:r,!t&&r>=a?e:za(e,t,r)}var Ka=xn||function(e){return zt.clearTimeout(e)};function Ja(e,t){if(t)return e.slice();var n=e.length,r=Ct?Ct(n):new e.constructor(n);return e.copy(r),r}function $a(e){var t=new e.constructor(e.byteLength);return new Tt(t).set(new Tt(e)),t}function Qa(e,t){var n=t?$a(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function Za(e,t){if(e!==t){var r=e!==n,a=null===e,o=e==e,i=xs(e),s=t!==n,c=null===t,u=t==t,l=xs(t);if(!c&&!l&&!i&&e>t||i&&s&&u&&!c&&!l||a&&s&&u||!r&&u||!o)return 1;if(!a&&!i&&!l&&e<t||l&&r&&o&&!a&&!i||c&&r&&o||!s&&o||!u)return-1}return 0}function eo(e,t,n,r){for(var a=-1,o=e.length,i=n.length,s=-1,c=t.length,u=Vn(o-i,0),l=Je(c+u),d=!r;++s<c;)l[s]=t[s];for(;++a<i;)(d||a<o)&&(l[n[a]]=e[a]);for(;u--;)l[s++]=e[a++];return l}function to(e,t,n,r){for(var a=-1,o=e.length,i=-1,s=n.length,c=-1,u=t.length,l=Vn(o-s,0),d=Je(l+u),f=!r;++a<l;)d[a]=e[a];for(var p=a;++c<u;)d[p+c]=t[c];for(;++i<s;)(f||a<o)&&(d[p+n[i]]=e[a++]);return d}function no(e,t){var n=-1,r=e.length;for(t||(t=Je(r));++n<r;)t[n]=e[n];return t}function ro(e,t,r,a){var o=!r;r||(r={});for(var i=-1,s=t.length;++i<s;){var c=t[i],u=a?a(r[c],e[c],c,r,e):n;u===n&&(u=e[c]),o?Dr(r,c,u):Ar(r,c,u)}return r}function ao(e,t){return function(n,r){var a=bs(n)?Bt:zr,o=t?t():{};return a(n,e,Io(r,2),o)}}function oo(e){return Oa(function(t,r){var a=-1,o=r.length,i=o>1?r[o-1]:n,s=o>2?r[2]:n;for(i=e.length>3&&"function"==typeof i?(o--,i):n,s&&Uo(r[0],r[1],s)&&(i=o<3?n:i,o=1),t=tt(t);++a<o;){var c=r[a];c&&e(t,c,a,i)}return t})}function io(e,t){return function(n,r){if(null==n)return n;if(!ys(n))return e(n,r);for(var a=n.length,o=t?a:-1,i=tt(n);(t?o--:++o<a)&&!1!==r(i[o],o,i););return n}}function so(e){return function(t,n,r){for(var a=-1,o=tt(t),i=r(t),s=i.length;s--;){var c=i[e?s:++a];if(!1===n(o[c],c,o))break}return t}}function co(e){return function(t){var r=En(t=Vs(t))?Tn(t):n,a=r?r[0]:t.charAt(0),o=r?Ga(r,1).join(""):t.slice(1);return a[e]()+o}}function uo(e){return function(t){return Qt(wc(vc(t).replace(mt,"")),e,"")}}function lo(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=hr(e.prototype),r=e.apply(n,t);return Ss(r)?r:n}}function fo(e){return function(t,r,a){var o=tt(t);if(!ys(t)){var i=Io(r,3);t=ac(t),r=function(e){return i(o[e],e,o)}}var s=e(t,r,a);return s>-1?o[i?t[s]:s]:n}}function po(e){return zo(function(t){var r=t.length,a=r,i=vr.prototype.thru;for(e&&t.reverse();a--;){var s=t[a];if("function"!=typeof s)throw new at(o);if(i&&!c&&"wrapper"==Po(s))var c=new vr([],!0)}for(a=c?a:r;++a<r;){var u=Po(s=t[a]),l="wrapper"==u?No(s):n;c=l&&Ko(l[0])&&l[1]==(M|b|y|E)&&!l[4].length&&1==l[9]?c[Po(l[0])].apply(c,l[3]):1==s.length&&Ko(s)?c[u]():c.thru(s)}return function(){var e=arguments,n=e[0];if(c&&1==e.length&&bs(n))return c.plant(n).value();for(var a=0,o=r?t[a].apply(this,e):n;++a<r;)o=t[a].call(this,o);return o}})}function ho(e,t,r,a,o,i,s,c,u,l){var d=t&M,f=t&h,p=t&m,v=t&(b|g),y=t&O,_=p?n:lo(e);return function h(){for(var m=arguments.length,b=Je(m),g=m;g--;)b[g]=arguments[g];if(v)var M=xo(h),E=function(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}(b,M);if(a&&(b=eo(b,a,o,v)),i&&(b=to(b,i,s,v)),m-=E,v&&m<l){var O=kn(b,M);return Mo(e,t,ho,h.placeholder,r,b,O,c,u,l-m)}var w=f?r:this,k=p?w[e]:e;return m=b.length,c?b=function(e,t){for(var r=e.length,a=Xn(t.length,r),o=no(e);a--;){var i=t[a];e[a]=Xo(i,r)?o[i]:n}return e}(b,c):y&&m>1&&b.reverse(),d&&u<m&&(b.length=u),this&&this!==zt&&this instanceof h&&(k=_||lo(k)),k.apply(w,b)}}function mo(e,t){return function(n,r){return function(e,t,n,r){return Ur(e,function(e,a,o){t(r,n(e),a,o)}),r}(n,e,t(r),{})}}function vo(e,t){return function(r,a){var o;if(r===n&&a===n)return t;if(r!==n&&(o=r),a!==n){if(o===n)return a;"string"==typeof r||"string"==typeof a?(r=Ia(r),a=Ia(a)):(r=xa(r),a=xa(a)),o=e(r,a)}return o}}function bo(e){return zo(function(t){return t=Jt(t,hn(Io())),Oa(function(n){var r=this;return e(t,function(e){return qt(e,r,n)})})})}function go(e,t){var r=(t=t===n?" ":Ia(t)).length;if(r<2)return r?Ea(t,e):t;var a=Ea(t,jn(e/An(t)));return En(t)?Ga(Tn(a),0,e).join(""):a.slice(0,e)}function yo(e){return function(t,r,a){return a&&"number"!=typeof a&&Uo(t,r,a)&&(r=a=n),t=Ws(t),r===n?(r=t,t=0):r=Ws(r),function(e,t,n,r){for(var a=-1,o=Vn(jn((t-e)/(n||1)),0),i=Je(o);o--;)i[r?o:++a]=e,e+=n;return i}(t,r,a=a===n?t<r?1:-1:Ws(a),e)}}function _o(e){return function(t,n){return"string"==typeof t&&"string"==typeof n||(t=Bs(t),n=Bs(n)),e(t,n)}}function Mo(e,t,r,a,o,i,s,c,u,l){var d=t&b;t|=d?y:_,(t&=~(d?_:y))&v||(t&=~(h|m));var f=[e,t,o,d?i:n,d?s:n,d?n:i,d?n:s,c,u,l],p=r.apply(n,f);return Ko(e)&&ri(p,f),p.placeholder=a,ii(p,e,t)}function Eo(e){var t=et[e];return function(e,n){if(e=Bs(e),(n=null==n?0:Xn(Ys(n),292))&&qn(e)){var r=(Vs(e)+"e").split("e");return+((r=(Vs(t(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return t(e)}}var Oo=er&&1/Ln(new er([,-0]))[1]==z?function(e){return new er(e)}:xc;function wo(e){return function(t){var n=qo(t);return n==U?On(t):n==Z?Sn(t):function(e,t){return Jt(t,function(t){return[t,e[t]]})}(t,e(t))}}function ko(e,t,r,a,i,s,u,l){var d=t&m;if(!d&&"function"!=typeof e)throw new at(o);var f=a?a.length:0;if(f||(t&=~(y|_),a=i=n),u=u===n?u:Vn(Ys(u),0),l=l===n?l:Ys(l),f-=i?i.length:0,t&_){var p=a,O=i;a=i=n}var w=d?n:No(e),k=[e,t,r,a,i,p,O,s,u,l];if(w&&function(e,t){var n=e[1],r=t[1],a=n|r,o=a<(h|m|M),i=r==M&&n==b||r==M&&n==E&&e[7].length<=t[8]||r==(M|E)&&t[7].length<=t[8]&&n==b;if(!o&&!i)return e;r&h&&(e[2]=t[2],a|=n&h?0:v);var s=t[3];if(s){var u=e[3];e[3]=u?eo(u,s,t[4]):s,e[4]=u?kn(e[3],c):t[4]}(s=t[5])&&(u=e[5],e[5]=u?to(u,s,t[6]):s,e[6]=u?kn(e[5],c):t[6]),(s=t[7])&&(e[7]=s),r&M&&(e[8]=null==e[8]?t[8]:Xn(e[8],t[8])),null==e[9]&&(e[9]=t[9]),e[0]=t[0],e[1]=a}(k,w),e=k[0],t=k[1],r=k[2],a=k[3],i=k[4],!(l=k[9]=k[9]===n?d?0:e.length:Vn(k[9]-f,0))&&t&(b|g)&&(t&=~(b|g)),t&&t!=h)L=t==b||t==g?function(e,t,r){var a=lo(e);return function o(){for(var i=arguments.length,s=Je(i),c=i,u=xo(o);c--;)s[c]=arguments[c];var l=i<3&&s[0]!==u&&s[i-1]!==u?[]:kn(s,u);return(i-=l.length)<r?Mo(e,t,ho,o.placeholder,n,s,l,n,n,r-i):qt(this&&this!==zt&&this instanceof o?a:e,this,s)}}(e,t,l):t!=y&&t!=(h|y)||i.length?ho.apply(n,k):function(e,t,n,r){var a=t&h,o=lo(e);return function t(){for(var i=-1,s=arguments.length,c=-1,u=r.length,l=Je(u+s),d=this&&this!==zt&&this instanceof t?o:e;++c<u;)l[c]=r[c];for(;s--;)l[c++]=arguments[++i];return qt(d,a?n:this,l)}}(e,t,r,a);else var L=function(e,t,n){var r=t&h,a=lo(e);return function t(){return(this&&this!==zt&&this instanceof t?a:e).apply(r?n:this,arguments)}}(e,t,r);return ii((w?Sa:ri)(L,k),e,t)}function Lo(e,t,r,a){return e===n||ps(e,st[r])&&!lt.call(a,r)?t:e}function So(e,t,r,a,o,i){return Ss(e)&&Ss(t)&&(i.set(t,e),ma(e,t,n,So,i),i.delete(t)),e}function Ao(e){return Cs(e)?n:e}function To(e,t,r,a,o,i){var s=r&f,c=e.length,u=t.length;if(c!=u&&!(s&&u>c))return!1;var l=i.get(e);if(l&&i.get(t))return l==t;var d=-1,h=!0,m=r&p?new Mr:n;for(i.set(e,t),i.set(t,e);++d<c;){var v=e[d],b=t[d];if(a)var g=s?a(b,v,d,t,e,i):a(v,b,d,e,t,i);if(g!==n){if(g)continue;h=!1;break}if(m){if(!en(t,function(e,t){if(!vn(m,t)&&(v===e||o(v,e,r,a,i)))return m.push(t)})){h=!1;break}}else if(v!==b&&!o(v,b,r,a,i)){h=!1;break}}return i.delete(e),i.delete(t),h}function zo(e){return oi(ei(e,n,gi),e+"")}function Co(e){return $r(e,ac,Wo)}function Do(e){return $r(e,oc,Yo)}var No=rr?function(e){return rr.get(e)}:xc;function Po(e){for(var t=e.name+"",n=ar[t],r=lt.call(ar,t)?n.length:0;r--;){var a=n[r],o=a.func;if(null==o||o==e)return a.name}return t}function xo(e){return(lt.call(pr,"placeholder")?pr:e).placeholder}function Io(){var e=pr.iteratee||Cc;return e=e===Cc?ca:e,arguments.length?e(arguments[0],arguments[1]):e}function Ro(e,t){var n,r,a=e.__data__;return("string"==(r=typeof(n=t))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?a["string"==typeof t?"string":"hash"]:a.map}function jo(e){for(var t=ac(e),n=t.length;n--;){var r=t[n],a=e[r];t[n]=[r,a,Qo(a)]}return t}function Ho(e,t){var r=function(e,t){return null==e?n:e[t]}(e,t);return sa(r)?r:n}var Wo=Wn?function(e){return null==e?[]:(e=tt(e),Ut(Wn(e),function(t){return xt.call(e,t)}))}:qc,Yo=Wn?function(e){for(var t=[];e;)$t(t,Wo(e)),e=Dt(e);return t}:qc,qo=Qr;function Bo(e,t,n){for(var r=-1,a=(t=Xa(t,e)).length,o=!1;++r<a;){var i=li(t[r]);if(!(o=null!=e&&n(e,i)))break;e=e[i]}return o||++r!=a?o:!!(a=null==e?0:e.length)&&Ls(a)&&Xo(i,a)&&(bs(e)||vs(e))}function Fo(e){return"function"!=typeof e.constructor||$o(e)?{}:hr(Dt(e))}function Vo(e){return bs(e)||vs(e)||!!(ln&&e&&e[ln])}function Xo(e,t){var n=typeof e;return!!(t=null==t?C:t)&&("number"==n||"symbol"!=n&&Ve.test(e))&&e>-1&&e%1==0&&e<t}function Uo(e,t,n){if(!Ss(n))return!1;var r=typeof t;return!!("number"==r?ys(n)&&Xo(t,n.length):"string"==r&&t in n)&&ps(n[t],e)}function Go(e,t){if(bs(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!xs(e))||Se.test(e)||!Le.test(e)||null!=t&&e in tt(t)}function Ko(e){var t=Po(e),n=pr[t];if("function"!=typeof n||!(t in br.prototype))return!1;if(e===n)return!0;var r=No(n);return!!r&&e===r[0]}($n&&qo(new $n(new ArrayBuffer(1)))!=ie||Qn&&qo(new Qn)!=U||Zn&&"[object Promise]"!=qo(Zn.resolve())||er&&qo(new er)!=Z||tr&&qo(new tr)!=re)&&(qo=function(e){var t=Qr(e),r=t==J?e.constructor:n,a=r?di(r):"";if(a)switch(a){case or:return ie;case ir:return U;case sr:return"[object Promise]";case cr:return Z;case ur:return re}return t});var Jo=ct?ws:Bc;function $o(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||st)}function Qo(e){return e==e&&!Ss(e)}function Zo(e,t){return function(r){return null!=r&&r[e]===t&&(t!==n||e in tt(r))}}function ei(e,t,r){return t=Vn(t===n?e.length-1:t,0),function(){for(var n=arguments,a=-1,o=Vn(n.length-t,0),i=Je(o);++a<o;)i[a]=n[t+a];a=-1;for(var s=Je(t+1);++a<t;)s[a]=n[a];return s[t]=r(i),qt(e,this,s)}}function ti(e,t){return t.length<2?e:Jr(e,za(t,0,-1))}function ni(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}var ri=si(Sa),ai=Rn||function(e,t){return zt.setTimeout(e,t)},oi=si(Aa);function ii(e,t,n){var r=t+"";return oi(e,function(e,t){var n=t.length;if(!n)return e;var r=n-1;return t[r]=(n>1?"& ":"")+t[r],t=t.join(n>2?", ":" "),e.replace(Pe,"{\n/* [wrapped with "+t+"] */\n")}(r,function(e,t){return Ft(R,function(n){var r="_."+n[0];t&n[1]&&!Gt(e,r)&&e.push(r)}),e.sort()}(function(e){var t=e.match(xe);return t?t[1].split(Ie):[]}(r),n)))}function si(e){var t=0,r=0;return function(){var a=Un(),o=S-(a-r);if(r=a,o>0){if(++t>=L)return arguments[0]}else t=0;return e.apply(n,arguments)}}function ci(e,t){var r=-1,a=e.length,o=a-1;for(t=t===n?a:t;++r<t;){var i=Ma(r,o),s=e[i];e[i]=e[r],e[r]=s}return e.length=t,e}var ui=function(e){var t=ss(e,function(e){return n.size===s&&n.clear(),e}),n=t.cache;return t}(function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(Ae,function(e,n,r,a){t.push(r?a.replace(je,"$1"):n||e)}),t});function li(e){if("string"==typeof e||xs(e))return e;var t=e+"";return"0"==t&&1/e==-z?"-0":t}function di(e){if(null!=e){try{return ut.call(e)}catch(t){}try{return e+""}catch(t){}}return""}function fi(e){if(e instanceof br)return e.clone();var t=new vr(e.__wrapped__,e.__chain__);return t.__actions__=no(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}var pi=Oa(function(e,t){return _s(e)?jr(e,Fr(t,1,_s,!0)):[]}),hi=Oa(function(e,t){var r=Oi(t);return _s(r)&&(r=n),_s(e)?jr(e,Fr(t,1,_s,!0),Io(r,2)):[]}),mi=Oa(function(e,t){var r=Oi(t);return _s(r)&&(r=n),_s(e)?jr(e,Fr(t,1,_s,!0),n,r):[]});function vi(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var a=null==n?0:Ys(n);return a<0&&(a=Vn(r+a,0)),rn(e,Io(t,3),a)}function bi(e,t,r){var a=null==e?0:e.length;if(!a)return-1;var o=a-1;return r!==n&&(o=Ys(r),o=r<0?Vn(a+o,0):Xn(o,a-1)),rn(e,Io(t,3),o,!0)}function gi(e){return null!=e&&e.length?Fr(e,1):[]}function yi(e){return e&&e.length?e[0]:n}var _i=Oa(function(e){var t=Jt(e,Fa);return t.length&&t[0]===e[0]?na(t):[]}),Mi=Oa(function(e){var t=Oi(e),r=Jt(e,Fa);return t===Oi(r)?t=n:r.pop(),r.length&&r[0]===e[0]?na(r,Io(t,2)):[]}),Ei=Oa(function(e){var t=Oi(e),r=Jt(e,Fa);return(t="function"==typeof t?t:n)&&r.pop(),r.length&&r[0]===e[0]?na(r,n,t):[]});function Oi(e){var t=null==e?0:e.length;return t?e[t-1]:n}var wi=Oa(ki);function ki(e,t){return e&&e.length&&t&&t.length?ya(e,t):e}var Li=zo(function(e,t){var n=null==e?0:e.length,r=Nr(e,t);return _a(e,Jt(t,function(e){return Xo(e,n)?+e:e}).sort(Za)),r});function Si(e){return null==e?e:Jn.call(e)}var Ai=Oa(function(e){return Ra(Fr(e,1,_s,!0))}),Ti=Oa(function(e){var t=Oi(e);return _s(t)&&(t=n),Ra(Fr(e,1,_s,!0),Io(t,2))}),zi=Oa(function(e){var t=Oi(e);return t="function"==typeof t?t:n,Ra(Fr(e,1,_s,!0),n,t)});function Ci(e){if(!e||!e.length)return[];var t=0;return e=Ut(e,function(e){if(_s(e))return t=Vn(e.length,t),!0}),pn(t,function(t){return Jt(e,un(t))})}function Di(e,t){if(!e||!e.length)return[];var r=Ci(e);return null==t?r:Jt(r,function(e){return qt(t,n,e)})}var Ni=Oa(function(e,t){return _s(e)?jr(e,t):[]}),Pi=Oa(function(e){return qa(Ut(e,_s))}),xi=Oa(function(e){var t=Oi(e);return _s(t)&&(t=n),qa(Ut(e,_s),Io(t,2))}),Ii=Oa(function(e){var t=Oi(e);return t="function"==typeof t?t:n,qa(Ut(e,_s),n,t)}),Ri=Oa(Ci);var ji=Oa(function(e){var t=e.length,r=t>1?e[t-1]:n;return r="function"==typeof r?(e.pop(),r):n,Di(e,r)});function Hi(e){var t=pr(e);return t.__chain__=!0,t}function Wi(e,t){return t(e)}var Yi=zo(function(e){var t=e.length,r=t?e[0]:0,a=this.__wrapped__,o=function(t){return Nr(t,e)};return!(t>1||this.__actions__.length)&&a instanceof br&&Xo(r)?((a=a.slice(r,+r+(t?1:0))).__actions__.push({func:Wi,args:[o],thisArg:n}),new vr(a,this.__chain__).thru(function(e){return t&&!e.length&&e.push(n),e})):this.thru(o)});var qi=ao(function(e,t,n){lt.call(e,n)?++e[n]:Dr(e,n,1)});var Bi=fo(vi),Fi=fo(bi);function Vi(e,t){return(bs(e)?Ft:Hr)(e,Io(t,3))}function Xi(e,t){return(bs(e)?Vt:Wr)(e,Io(t,3))}var Ui=ao(function(e,t,n){lt.call(e,n)?e[n].push(t):Dr(e,n,[t])});var Gi=Oa(function(e,t,n){var r=-1,a="function"==typeof t,o=ys(e)?Je(e.length):[];return Hr(e,function(e){o[++r]=a?qt(t,e,n):ra(e,t,n)}),o}),Ki=ao(function(e,t,n){Dr(e,n,t)});function Ji(e,t){return(bs(e)?Jt:fa)(e,Io(t,3))}var $i=ao(function(e,t,n){e[n?0:1].push(t)},function(){return[[],[]]});var Qi=Oa(function(e,t){if(null==e)return[];var n=t.length;return n>1&&Uo(e,t[0],t[1])?t=[]:n>2&&Uo(t[0],t[1],t[2])&&(t=[t[0]]),ba(e,Fr(t,1),[])}),Zi=In||function(){return zt.Date.now()};function es(e,t,r){return t=r?n:t,t=e&&null==t?e.length:t,ko(e,M,n,n,n,n,t)}function ts(e,t){var r;if("function"!=typeof t)throw new at(o);return e=Ys(e),function(){return--e>0&&(r=t.apply(this,arguments)),e<=1&&(t=n),r}}var ns=Oa(function(e,t,n){var r=h;if(n.length){var a=kn(n,xo(ns));r|=y}return ko(e,r,t,n,a)}),rs=Oa(function(e,t,n){var r=h|m;if(n.length){var a=kn(n,xo(rs));r|=y}return ko(t,r,e,n,a)});function as(e,t,r){var a,i,s,c,u,l,d=0,f=!1,p=!1,h=!0;if("function"!=typeof e)throw new at(o);function m(t){var r=a,o=i;return a=i=n,d=t,c=e.apply(o,r)}function v(e){var r=e-l;return l===n||r>=t||r<0||p&&e-d>=s}function b(){var e=Zi();if(v(e))return g(e);u=ai(b,function(e){var n=t-(e-l);return p?Xn(n,s-(e-d)):n}(e))}function g(e){return u=n,h&&a?m(e):(a=i=n,c)}function y(){var e=Zi(),r=v(e);if(a=arguments,i=this,l=e,r){if(u===n)return function(e){return d=e,u=ai(b,t),f?m(e):c}(l);if(p)return Ka(u),u=ai(b,t),m(l)}return u===n&&(u=ai(b,t)),c}return t=Bs(t)||0,Ss(r)&&(f=!!r.leading,s=(p="maxWait"in r)?Vn(Bs(r.maxWait)||0,t):s,h="trailing"in r?!!r.trailing:h),y.cancel=function(){u!==n&&Ka(u),d=0,a=l=i=u=n},y.flush=function(){return u===n?c:g(Zi())},y}var os=Oa(function(e,t){return Rr(e,1,t)}),is=Oa(function(e,t,n){return Rr(e,Bs(t)||0,n)});function ss(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new at(o);var n=function(){var r=arguments,a=t?t.apply(this,r):r[0],o=n.cache;if(o.has(a))return o.get(a);var i=e.apply(this,r);return n.cache=o.set(a,i)||o,i};return n.cache=new(ss.Cache||_r),n}function cs(e){if("function"!=typeof e)throw new at(o);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}ss.Cache=_r;var us=Ua(function(e,t){var n=(t=1==t.length&&bs(t[0])?Jt(t[0],hn(Io())):Jt(Fr(t,1),hn(Io()))).length;return Oa(function(r){for(var a=-1,o=Xn(r.length,n);++a<o;)r[a]=t[a].call(this,r[a]);return qt(e,this,r)})}),ls=Oa(function(e,t){var r=kn(t,xo(ls));return ko(e,y,n,t,r)}),ds=Oa(function(e,t){var r=kn(t,xo(ds));return ko(e,_,n,t,r)}),fs=zo(function(e,t){return ko(e,E,n,n,n,t)});function ps(e,t){return e===t||e!=e&&t!=t}var hs=_o(Zr),ms=_o(function(e,t){return e>=t}),vs=aa(function(){return arguments}())?aa:function(e){return As(e)&&lt.call(e,"callee")&&!xt.call(e,"callee")},bs=Je.isArray,gs=It?hn(It):function(e){return As(e)&&Qr(e)==oe};function ys(e){return null!=e&&Ls(e.length)&&!ws(e)}function _s(e){return As(e)&&ys(e)}var Ms=Yn||Bc,Es=Rt?hn(Rt):function(e){return As(e)&&Qr(e)==q};function Os(e){if(!As(e))return!1;var t=Qr(e);return t==F||t==B||"string"==typeof e.message&&"string"==typeof e.name&&!Cs(e)}function ws(e){if(!Ss(e))return!1;var t=Qr(e);return t==V||t==X||t==W||t==$}function ks(e){return"number"==typeof e&&e==Ys(e)}function Ls(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=C}function Ss(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function As(e){return null!=e&&"object"==typeof e}var Ts=jt?hn(jt):function(e){return As(e)&&qo(e)==U};function zs(e){return"number"==typeof e||As(e)&&Qr(e)==G}function Cs(e){if(!As(e)||Qr(e)!=J)return!1;var t=Dt(e);if(null===t)return!0;var n=lt.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&ut.call(n)==ht}var Ds=Ht?hn(Ht):function(e){return As(e)&&Qr(e)==Q};var Ns=Wt?hn(Wt):function(e){return As(e)&&qo(e)==Z};function Ps(e){return"string"==typeof e||!bs(e)&&As(e)&&Qr(e)==ee}function xs(e){return"symbol"==typeof e||As(e)&&Qr(e)==te}var Is=Yt?hn(Yt):function(e){return As(e)&&Ls(e.length)&&!!Ot[Qr(e)]};var Rs=_o(da),js=_o(function(e,t){return e<=t});function Hs(e){if(!e)return[];if(ys(e))return Ps(e)?Tn(e):no(e);if(Dn&&e[Dn])return function(e){for(var t,n=[];!(t=e.next()).done;)n.push(t.value);return n}(e[Dn]());var t=qo(e);return(t==U?On:t==Z?Ln:pc)(e)}function Ws(e){return e?(e=Bs(e))===z||e===-z?(e<0?-1:1)*D:e==e?e:0:0===e?e:0}function Ys(e){var t=Ws(e),n=t%1;return t==t?n?t-n:t:0}function qs(e){return e?Pr(Ys(e),0,P):0}function Bs(e){if("number"==typeof e)return e;if(xs(e))return N;if(Ss(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=Ss(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(Ce,"");var n=qe.test(e);return n||Fe.test(e)?St(e.slice(2),n?2:8):Ye.test(e)?N:+e}function Fs(e){return ro(e,oc(e))}function Vs(e){return null==e?"":Ia(e)}var Xs=oo(function(e,t){if($o(t)||ys(t))ro(t,ac(t),e);else for(var n in t)lt.call(t,n)&&Ar(e,n,t[n])}),Us=oo(function(e,t){ro(t,oc(t),e)}),Gs=oo(function(e,t,n,r){ro(t,oc(t),e,r)}),Ks=oo(function(e,t,n,r){ro(t,ac(t),e,r)}),Js=zo(Nr);var $s=Oa(function(e,t){e=tt(e);var r=-1,a=t.length,o=a>2?t[2]:n;for(o&&Uo(t[0],t[1],o)&&(a=1);++r<a;)for(var i=t[r],s=oc(i),c=-1,u=s.length;++c<u;){var l=s[c],d=e[l];(d===n||ps(d,st[l])&&!lt.call(e,l))&&(e[l]=i[l])}return e}),Qs=Oa(function(e){return e.push(n,So),qt(sc,n,e)});function Zs(e,t,r){var a=null==e?n:Jr(e,t);return a===n?r:a}function ec(e,t){return null!=e&&Bo(e,t,ta)}var tc=mo(function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=pt.call(t)),e[t]=n},Sc(zc)),nc=mo(function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=pt.call(t)),lt.call(e,t)?e[t].push(n):e[t]=[n]},Io),rc=Oa(ra);function ac(e){return ys(e)?Or(e):ua(e)}function oc(e){return ys(e)?Or(e,!0):la(e)}var ic=oo(function(e,t,n){ma(e,t,n)}),sc=oo(function(e,t,n,r){ma(e,t,n,r)}),cc=zo(function(e,t){var n={};if(null==e)return n;var r=!1;t=Jt(t,function(t){return t=Xa(t,e),r||(r=t.length>1),t}),ro(e,Do(e),n),r&&(n=xr(n,u|l|d,Ao));for(var a=t.length;a--;)ja(n,t[a]);return n});var uc=zo(function(e,t){return null==e?{}:function(e,t){return ga(e,t,function(t,n){return ec(e,n)})}(e,t)});function lc(e,t){if(null==e)return{};var n=Jt(Do(e),function(e){return[e]});return t=Io(t),ga(e,n,function(e,n){return t(e,n[0])})}var dc=wo(ac),fc=wo(oc);function pc(e){return null==e?[]:mn(e,ac(e))}var hc=uo(function(e,t,n){return t=t.toLowerCase(),e+(n?mc(t):t)});function mc(e){return Oc(Vs(e).toLowerCase())}function vc(e){return(e=Vs(e))&&e.replace(Xe,yn).replace(vt,"")}var bc=uo(function(e,t,n){return e+(n?"-":"")+t.toLowerCase()}),gc=uo(function(e,t,n){return e+(n?" ":"")+t.toLowerCase()}),yc=co("toLowerCase");var _c=uo(function(e,t,n){return e+(n?"_":"")+t.toLowerCase()});var Mc=uo(function(e,t,n){return e+(n?" ":"")+Oc(t)});var Ec=uo(function(e,t,n){return e+(n?" ":"")+t.toUpperCase()}),Oc=co("toUpperCase");function wc(e,t,r){return e=Vs(e),(t=r?n:t)===n?function(e){return _t.test(e)}(e)?function(e){return e.match(gt)||[]}(e):function(e){return e.match(Re)||[]}(e):e.match(t)||[]}var kc=Oa(function(e,t){try{return qt(e,n,t)}catch(r){return Os(r)?r:new Qe(r)}}),Lc=zo(function(e,t){return Ft(t,function(t){t=li(t),Dr(e,t,ns(e[t],e))}),e});function Sc(e){return function(){return e}}var Ac=po(),Tc=po(!0);function zc(e){return e}function Cc(e){return ca("function"==typeof e?e:xr(e,u))}var Dc=Oa(function(e,t){return function(n){return ra(n,e,t)}}),Nc=Oa(function(e,t){return function(n){return ra(e,n,t)}});function Pc(e,t,n){var r=ac(t),a=Kr(t,r);null!=n||Ss(t)&&(a.length||!r.length)||(n=t,t=e,e=this,a=Kr(t,ac(t)));var o=!(Ss(n)&&"chain"in n&&!n.chain),i=ws(e);return Ft(a,function(n){var r=t[n];e[n]=r,i&&(e.prototype[n]=function(){var t=this.__chain__;if(o||t){var n=e(this.__wrapped__);return(n.__actions__=no(this.__actions__)).push({func:r,args:arguments,thisArg:e}),n.__chain__=t,n}return r.apply(e,$t([this.value()],arguments))})}),e}function xc(){}var Ic=bo(Jt),Rc=bo(Xt),jc=bo(en);function Hc(e){return Go(e)?un(li(e)):function(e){return function(t){return Jr(t,e)}}(e)}var Wc=yo(),Yc=yo(!0);function qc(){return[]}function Bc(){return!1}var Fc=vo(function(e,t){return e+t},0),Vc=Eo("ceil"),Xc=vo(function(e,t){return e/t},1),Uc=Eo("floor");var Gc,Kc=vo(function(e,t){return e*t},1),Jc=Eo("round"),$c=vo(function(e,t){return e-t},0);return pr.after=function(e,t){if("function"!=typeof t)throw new at(o);return e=Ys(e),function(){if(--e<1)return t.apply(this,arguments)}},pr.ary=es,pr.assign=Xs,pr.assignIn=Us,pr.assignInWith=Gs,pr.assignWith=Ks,pr.at=Js,pr.before=ts,pr.bind=ns,pr.bindAll=Lc,pr.bindKey=rs,pr.castArray=function(){if(!arguments.length)return[];var e=arguments[0];return bs(e)?e:[e]},pr.chain=Hi,pr.chunk=function(e,t,r){t=(r?Uo(e,t,r):t===n)?1:Vn(Ys(t),0);var a=null==e?0:e.length;if(!a||t<1)return[];for(var o=0,i=0,s=Je(jn(a/t));o<a;)s[i++]=za(e,o,o+=t);return s},pr.compact=function(e){for(var t=-1,n=null==e?0:e.length,r=0,a=[];++t<n;){var o=e[t];o&&(a[r++]=o)}return a},pr.concat=function(){var e=arguments.length;if(!e)return[];for(var t=Je(e-1),n=arguments[0],r=e;r--;)t[r-1]=arguments[r];return $t(bs(n)?no(n):[n],Fr(t,1))},pr.cond=function(e){var t=null==e?0:e.length,n=Io();return e=t?Jt(e,function(e){if("function"!=typeof e[1])throw new at(o);return[n(e[0]),e[1]]}):[],Oa(function(n){for(var r=-1;++r<t;){var a=e[r];if(qt(a[0],this,n))return qt(a[1],this,n)}})},pr.conforms=function(e){return function(e){var t=ac(e);return function(n){return Ir(n,e,t)}}(xr(e,u))},pr.constant=Sc,pr.countBy=qi,pr.create=function(e,t){var n=hr(e);return null==t?n:Cr(n,t)},pr.curry=function e(t,r,a){var o=ko(t,b,n,n,n,n,n,r=a?n:r);return o.placeholder=e.placeholder,o},pr.curryRight=function e(t,r,a){var o=ko(t,g,n,n,n,n,n,r=a?n:r);return o.placeholder=e.placeholder,o},pr.debounce=as,pr.defaults=$s,pr.defaultsDeep=Qs,pr.defer=os,pr.delay=is,pr.difference=pi,pr.differenceBy=hi,pr.differenceWith=mi,pr.drop=function(e,t,r){var a=null==e?0:e.length;return a?za(e,(t=r||t===n?1:Ys(t))<0?0:t,a):[]},pr.dropRight=function(e,t,r){var a=null==e?0:e.length;return a?za(e,0,(t=a-(t=r||t===n?1:Ys(t)))<0?0:t):[]},pr.dropRightWhile=function(e,t){return e&&e.length?Wa(e,Io(t,3),!0,!0):[]},pr.dropWhile=function(e,t){return e&&e.length?Wa(e,Io(t,3),!0):[]},pr.fill=function(e,t,r,a){var o=null==e?0:e.length;return o?(r&&"number"!=typeof r&&Uo(e,t,r)&&(r=0,a=o),function(e,t,r,a){var o=e.length;for((r=Ys(r))<0&&(r=-r>o?0:o+r),(a=a===n||a>o?o:Ys(a))<0&&(a+=o),a=r>a?0:qs(a);r<a;)e[r++]=t;return e}(e,t,r,a)):[]},pr.filter=function(e,t){return(bs(e)?Ut:Br)(e,Io(t,3))},pr.flatMap=function(e,t){return Fr(Ji(e,t),1)},pr.flatMapDeep=function(e,t){return Fr(Ji(e,t),z)},pr.flatMapDepth=function(e,t,r){return r=r===n?1:Ys(r),Fr(Ji(e,t),r)},pr.flatten=gi,pr.flattenDeep=function(e){return null!=e&&e.length?Fr(e,z):[]},pr.flattenDepth=function(e,t){return null!=e&&e.length?Fr(e,t=t===n?1:Ys(t)):[]},pr.flip=function(e){return ko(e,O)},pr.flow=Ac,pr.flowRight=Tc,pr.fromPairs=function(e){for(var t=-1,n=null==e?0:e.length,r={};++t<n;){var a=e[t];r[a[0]]=a[1]}return r},pr.functions=function(e){return null==e?[]:Kr(e,ac(e))},pr.functionsIn=function(e){return null==e?[]:Kr(e,oc(e))},pr.groupBy=Ui,pr.initial=function(e){return null!=e&&e.length?za(e,0,-1):[]},pr.intersection=_i,pr.intersectionBy=Mi,pr.intersectionWith=Ei,pr.invert=tc,pr.invertBy=nc,pr.invokeMap=Gi,pr.iteratee=Cc,pr.keyBy=Ki,pr.keys=ac,pr.keysIn=oc,pr.map=Ji,pr.mapKeys=function(e,t){var n={};return t=Io(t,3),Ur(e,function(e,r,a){Dr(n,t(e,r,a),e)}),n},pr.mapValues=function(e,t){var n={};return t=Io(t,3),Ur(e,function(e,r,a){Dr(n,r,t(e,r,a))}),n},pr.matches=function(e){return pa(xr(e,u))},pr.matchesProperty=function(e,t){return ha(e,xr(t,u))},pr.memoize=ss,pr.merge=ic,pr.mergeWith=sc,pr.method=Dc,pr.methodOf=Nc,pr.mixin=Pc,pr.negate=cs,pr.nthArg=function(e){return e=Ys(e),Oa(function(t){return va(t,e)})},pr.omit=cc,pr.omitBy=function(e,t){return lc(e,cs(Io(t)))},pr.once=function(e){return ts(2,e)},pr.orderBy=function(e,t,r,a){return null==e?[]:(bs(t)||(t=null==t?[]:[t]),bs(r=a?n:r)||(r=null==r?[]:[r]),ba(e,t,r))},pr.over=Ic,pr.overArgs=us,pr.overEvery=Rc,pr.overSome=jc,pr.partial=ls,pr.partialRight=ds,pr.partition=$i,pr.pick=uc,pr.pickBy=lc,pr.property=Hc,pr.propertyOf=function(e){return function(t){return null==e?n:Jr(e,t)}},pr.pull=wi,pr.pullAll=ki,pr.pullAllBy=function(e,t,n){return e&&e.length&&t&&t.length?ya(e,t,Io(n,2)):e},pr.pullAllWith=function(e,t,r){return e&&e.length&&t&&t.length?ya(e,t,n,r):e},pr.pullAt=Li,pr.range=Wc,pr.rangeRight=Yc,pr.rearg=fs,pr.reject=function(e,t){return(bs(e)?Ut:Br)(e,cs(Io(t,3)))},pr.remove=function(e,t){var n=[];if(!e||!e.length)return n;var r=-1,a=[],o=e.length;for(t=Io(t,3);++r<o;){var i=e[r];t(i,r,e)&&(n.push(i),a.push(r))}return _a(e,a),n},pr.rest=function(e,t){if("function"!=typeof e)throw new at(o);return Oa(e,t=t===n?t:Ys(t))},pr.reverse=Si,pr.sampleSize=function(e,t,r){return t=(r?Uo(e,t,r):t===n)?1:Ys(t),(bs(e)?kr:ka)(e,t)},pr.set=function(e,t,n){return null==e?e:La(e,t,n)},pr.setWith=function(e,t,r,a){return a="function"==typeof a?a:n,null==e?e:La(e,t,r,a)},pr.shuffle=function(e){return(bs(e)?Lr:Ta)(e)},pr.slice=function(e,t,r){var a=null==e?0:e.length;return a?(r&&"number"!=typeof r&&Uo(e,t,r)?(t=0,r=a):(t=null==t?0:Ys(t),r=r===n?a:Ys(r)),za(e,t,r)):[]},pr.sortBy=Qi,pr.sortedUniq=function(e){return e&&e.length?Pa(e):[]},pr.sortedUniqBy=function(e,t){return e&&e.length?Pa(e,Io(t,2)):[]},pr.split=function(e,t,r){return r&&"number"!=typeof r&&Uo(e,t,r)&&(t=r=n),(r=r===n?P:r>>>0)?(e=Vs(e))&&("string"==typeof t||null!=t&&!Ds(t))&&!(t=Ia(t))&&En(e)?Ga(Tn(e),0,r):e.split(t,r):[]},pr.spread=function(e,t){if("function"!=typeof e)throw new at(o);return t=null==t?0:Vn(Ys(t),0),Oa(function(n){var r=n[t],a=Ga(n,0,t);return r&&$t(a,r),qt(e,this,a)})},pr.tail=function(e){var t=null==e?0:e.length;return t?za(e,1,t):[]},pr.take=function(e,t,r){return e&&e.length?za(e,0,(t=r||t===n?1:Ys(t))<0?0:t):[]},pr.takeRight=function(e,t,r){var a=null==e?0:e.length;return a?za(e,(t=a-(t=r||t===n?1:Ys(t)))<0?0:t,a):[]},pr.takeRightWhile=function(e,t){return e&&e.length?Wa(e,Io(t,3),!1,!0):[]},pr.takeWhile=function(e,t){return e&&e.length?Wa(e,Io(t,3)):[]},pr.tap=function(e,t){return t(e),e},pr.throttle=function(e,t,n){var r=!0,a=!0;if("function"!=typeof e)throw new at(o);return Ss(n)&&(r="leading"in n?!!n.leading:r,a="trailing"in n?!!n.trailing:a),as(e,t,{leading:r,maxWait:t,trailing:a})},pr.thru=Wi,pr.toArray=Hs,pr.toPairs=dc,pr.toPairsIn=fc,pr.toPath=function(e){return bs(e)?Jt(e,li):xs(e)?[e]:no(ui(Vs(e)))},pr.toPlainObject=Fs,pr.transform=function(e,t,n){var r=bs(e),a=r||Ms(e)||Is(e);if(t=Io(t,4),null==n){var o=e&&e.constructor;n=a?r?new o:[]:Ss(e)&&ws(o)?hr(Dt(e)):{}}return(a?Ft:Ur)(e,function(e,r,a){return t(n,e,r,a)}),n},pr.unary=function(e){return es(e,1)},pr.union=Ai,pr.unionBy=Ti,pr.unionWith=zi,pr.uniq=function(e){return e&&e.length?Ra(e):[]},pr.uniqBy=function(e,t){return e&&e.length?Ra(e,Io(t,2)):[]},pr.uniqWith=function(e,t){return t="function"==typeof t?t:n,e&&e.length?Ra(e,n,t):[]},pr.unset=function(e,t){return null==e||ja(e,t)},pr.unzip=Ci,pr.unzipWith=Di,pr.update=function(e,t,n){return null==e?e:Ha(e,t,Va(n))},pr.updateWith=function(e,t,r,a){return a="function"==typeof a?a:n,null==e?e:Ha(e,t,Va(r),a)},pr.values=pc,pr.valuesIn=function(e){return null==e?[]:mn(e,oc(e))},pr.without=Ni,pr.words=wc,pr.wrap=function(e,t){return ls(Va(t),e)},pr.xor=Pi,pr.xorBy=xi,pr.xorWith=Ii,pr.zip=Ri,pr.zipObject=function(e,t){return Ba(e||[],t||[],Ar)},pr.zipObjectDeep=function(e,t){return Ba(e||[],t||[],La)},pr.zipWith=ji,pr.entries=dc,pr.entriesIn=fc,pr.extend=Us,pr.extendWith=Gs,Pc(pr,pr),pr.add=Fc,pr.attempt=kc,pr.camelCase=hc,pr.capitalize=mc,pr.ceil=Vc,pr.clamp=function(e,t,r){return r===n&&(r=t,t=n),r!==n&&(r=(r=Bs(r))==r?r:0),t!==n&&(t=(t=Bs(t))==t?t:0),Pr(Bs(e),t,r)},pr.clone=function(e){return xr(e,d)},pr.cloneDeep=function(e){return xr(e,u|d)},pr.cloneDeepWith=function(e,t){return xr(e,u|d,t="function"==typeof t?t:n)},pr.cloneWith=function(e,t){return xr(e,d,t="function"==typeof t?t:n)},pr.conformsTo=function(e,t){return null==t||Ir(e,t,ac(t))},pr.deburr=vc,pr.defaultTo=function(e,t){return null==e||e!=e?t:e},pr.divide=Xc,pr.endsWith=function(e,t,r){e=Vs(e),t=Ia(t);var a=e.length,o=r=r===n?a:Pr(Ys(r),0,a);return(r-=t.length)>=0&&e.slice(r,o)==t},pr.eq=ps,pr.escape=function(e){return(e=Vs(e))&&Ee.test(e)?e.replace(_e,_n):e},pr.escapeRegExp=function(e){return(e=Vs(e))&&ze.test(e)?e.replace(Te,"\\$&"):e},pr.every=function(e,t,r){var a=bs(e)?Xt:Yr;return r&&Uo(e,t,r)&&(t=n),a(e,Io(t,3))},pr.find=Bi,pr.findIndex=vi,pr.findKey=function(e,t){return nn(e,Io(t,3),Ur)},pr.findLast=Fi,pr.findLastIndex=bi,pr.findLastKey=function(e,t){return nn(e,Io(t,3),Gr)},pr.floor=Uc,pr.forEach=Vi,pr.forEachRight=Xi,pr.forIn=function(e,t){return null==e?e:Vr(e,Io(t,3),oc)},pr.forInRight=function(e,t){return null==e?e:Xr(e,Io(t,3),oc)},pr.forOwn=function(e,t){return e&&Ur(e,Io(t,3))},pr.forOwnRight=function(e,t){return e&&Gr(e,Io(t,3))},pr.get=Zs,pr.gt=hs,pr.gte=ms,pr.has=function(e,t){return null!=e&&Bo(e,t,ea)},pr.hasIn=ec,pr.head=yi,pr.identity=zc,pr.includes=function(e,t,n,r){e=ys(e)?e:pc(e),n=n&&!r?Ys(n):0;var a=e.length;return n<0&&(n=Vn(a+n,0)),Ps(e)?n<=a&&e.indexOf(t,n)>-1:!!a&&an(e,t,n)>-1},pr.indexOf=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var a=null==n?0:Ys(n);return a<0&&(a=Vn(r+a,0)),an(e,t,a)},pr.inRange=function(e,t,r){return t=Ws(t),r===n?(r=t,t=0):r=Ws(r),function(e,t,n){return e>=Xn(t,n)&&e<Vn(t,n)}(e=Bs(e),t,r)},pr.invoke=rc,pr.isArguments=vs,pr.isArray=bs,pr.isArrayBuffer=gs,pr.isArrayLike=ys,pr.isArrayLikeObject=_s,pr.isBoolean=function(e){return!0===e||!1===e||As(e)&&Qr(e)==Y},pr.isBuffer=Ms,pr.isDate=Es,pr.isElement=function(e){return As(e)&&1===e.nodeType&&!Cs(e)},pr.isEmpty=function(e){if(null==e)return!0;if(ys(e)&&(bs(e)||"string"==typeof e||"function"==typeof e.splice||Ms(e)||Is(e)||vs(e)))return!e.length;var t=qo(e);if(t==U||t==Z)return!e.size;if($o(e))return!ua(e).length;for(var n in e)if(lt.call(e,n))return!1;return!0},pr.isEqual=function(e,t){return oa(e,t)},pr.isEqualWith=function(e,t,r){var a=(r="function"==typeof r?r:n)?r(e,t):n;return a===n?oa(e,t,n,r):!!a},pr.isError=Os,pr.isFinite=function(e){return"number"==typeof e&&qn(e)},pr.isFunction=ws,pr.isInteger=ks,pr.isLength=Ls,pr.isMap=Ts,pr.isMatch=function(e,t){return e===t||ia(e,t,jo(t))},pr.isMatchWith=function(e,t,r){return r="function"==typeof r?r:n,ia(e,t,jo(t),r)},pr.isNaN=function(e){return zs(e)&&e!=+e},pr.isNative=function(e){if(Jo(e))throw new Qe(a);return sa(e)},pr.isNil=function(e){return null==e},pr.isNull=function(e){return null===e},pr.isNumber=zs,pr.isObject=Ss,pr.isObjectLike=As,pr.isPlainObject=Cs,pr.isRegExp=Ds,pr.isSafeInteger=function(e){return ks(e)&&e>=-C&&e<=C},pr.isSet=Ns,pr.isString=Ps,pr.isSymbol=xs,pr.isTypedArray=Is,pr.isUndefined=function(e){return e===n},pr.isWeakMap=function(e){return As(e)&&qo(e)==re},pr.isWeakSet=function(e){return As(e)&&Qr(e)==ae},pr.join=function(e,t){return null==e?"":Bn.call(e,t)},pr.kebabCase=bc,pr.last=Oi,pr.lastIndexOf=function(e,t,r){var a=null==e?0:e.length;if(!a)return-1;var o=a;return r!==n&&(o=(o=Ys(r))<0?Vn(a+o,0):Xn(o,a-1)),t==t?function(e,t,n){for(var r=n+1;r--;)if(e[r]===t)return r;return r}(e,t,o):rn(e,sn,o,!0)},pr.lowerCase=gc,pr.lowerFirst=yc,pr.lt=Rs,pr.lte=js,pr.max=function(e){return e&&e.length?qr(e,zc,Zr):n},pr.maxBy=function(e,t){return e&&e.length?qr(e,Io(t,2),Zr):n},pr.mean=function(e){return cn(e,zc)},pr.meanBy=function(e,t){return cn(e,Io(t,2))},pr.min=function(e){return e&&e.length?qr(e,zc,da):n},pr.minBy=function(e,t){return e&&e.length?qr(e,Io(t,2),da):n},pr.stubArray=qc,pr.stubFalse=Bc,pr.stubObject=function(){return{}},pr.stubString=function(){return""},pr.stubTrue=function(){return!0},pr.multiply=Kc,pr.nth=function(e,t){return e&&e.length?va(e,Ys(t)):n},pr.noConflict=function(){return zt._===this&&(zt._=bt),this},pr.noop=xc,pr.now=Zi,pr.pad=function(e,t,n){e=Vs(e);var r=(t=Ys(t))?An(e):0;if(!t||r>=t)return e;var a=(t-r)/2;return go(Hn(a),n)+e+go(jn(a),n)},pr.padEnd=function(e,t,n){e=Vs(e);var r=(t=Ys(t))?An(e):0;return t&&r<t?e+go(t-r,n):e},pr.padStart=function(e,t,n){e=Vs(e);var r=(t=Ys(t))?An(e):0;return t&&r<t?go(t-r,n)+e:e},pr.parseInt=function(e,t,n){return n||null==t?t=0:t&&(t=+t),Gn(Vs(e).replace(De,""),t||0)},pr.random=function(e,t,r){if(r&&"boolean"!=typeof r&&Uo(e,t,r)&&(t=r=n),r===n&&("boolean"==typeof t?(r=t,t=n):"boolean"==typeof e&&(r=e,e=n)),e===n&&t===n?(e=0,t=1):(e=Ws(e),t===n?(t=e,e=0):t=Ws(t)),e>t){var a=e;e=t,t=a}if(r||e%1||t%1){var o=Kn();return Xn(e+o*(t-e+Lt("1e-"+((o+"").length-1))),t)}return Ma(e,t)},pr.reduce=function(e,t,n){var r=bs(e)?Qt:dn,a=arguments.length<3;return r(e,Io(t,4),n,a,Hr)},pr.reduceRight=function(e,t,n){var r=bs(e)?Zt:dn,a=arguments.length<3;return r(e,Io(t,4),n,a,Wr)},pr.repeat=function(e,t,r){return t=(r?Uo(e,t,r):t===n)?1:Ys(t),Ea(Vs(e),t)},pr.replace=function(){var e=arguments,t=Vs(e[0]);return e.length<3?t:t.replace(e[1],e[2])},pr.result=function(e,t,r){var a=-1,o=(t=Xa(t,e)).length;for(o||(o=1,e=n);++a<o;){var i=null==e?n:e[li(t[a])];i===n&&(a=o,i=r),e=ws(i)?i.call(e):i}return e},pr.round=Jc,pr.runInContext=e,pr.sample=function(e){return(bs(e)?wr:wa)(e)},pr.size=function(e){if(null==e)return 0;if(ys(e))return Ps(e)?An(e):e.length;var t=qo(e);return t==U||t==Z?e.size:ua(e).length},pr.snakeCase=_c,pr.some=function(e,t,r){var a=bs(e)?en:Ca;return r&&Uo(e,t,r)&&(t=n),a(e,Io(t,3))},pr.sortedIndex=function(e,t){return Da(e,t)},pr.sortedIndexBy=function(e,t,n){return Na(e,t,Io(n,2))},pr.sortedIndexOf=function(e,t){var n=null==e?0:e.length;if(n){var r=Da(e,t);if(r<n&&ps(e[r],t))return r}return-1},pr.sortedLastIndex=function(e,t){return Da(e,t,!0)},pr.sortedLastIndexBy=function(e,t,n){return Na(e,t,Io(n,2),!0)},pr.sortedLastIndexOf=function(e,t){if(null!=e&&e.length){var n=Da(e,t,!0)-1;if(ps(e[n],t))return n}return-1},pr.startCase=Mc,pr.startsWith=function(e,t,n){return e=Vs(e),n=null==n?0:Pr(Ys(n),0,e.length),t=Ia(t),e.slice(n,n+t.length)==t},pr.subtract=$c,pr.sum=function(e){return e&&e.length?fn(e,zc):0},pr.sumBy=function(e,t){return e&&e.length?fn(e,Io(t,2)):0},pr.template=function(e,t,r){var a=pr.templateSettings;r&&Uo(e,t,r)&&(t=n),e=Vs(e),t=Gs({},t,a,Lo);var o,i,s=Gs({},t.imports,a.imports,Lo),c=ac(s),u=mn(s,c),l=0,d=t.interpolate||Ue,f="__p += '",p=nt((t.escape||Ue).source+"|"+d.source+"|"+(d===ke?He:Ue).source+"|"+(t.evaluate||Ue).source+"|$","g"),h="//# sourceURL="+(lt.call(t,"sourceURL")?(t.sourceURL+"").replace(/[\r\n]/g," "):"lodash.templateSources["+ ++Et+"]")+"\n";e.replace(p,function(t,n,r,a,s,c){return r||(r=a),f+=e.slice(l,c).replace(Ge,Mn),n&&(o=!0,f+="' +\n__e("+n+") +\n'"),s&&(i=!0,f+="';\n"+s+";\n__p += '"),r&&(f+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=c+t.length,t}),f+="';\n";var m=lt.call(t,"variable")&&t.variable;m||(f="with (obj) {\n"+f+"\n}\n"),f=(i?f.replace(ve,""):f).replace(be,"$1").replace(ge,"$1;"),f="function("+(m||"obj")+") {\n"+(m?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(o?", __e = _.escape":"")+(i?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+f+"return __p\n}";var v=kc(function(){return Ze(c,h+"return "+f).apply(n,u)});if(v.source=f,Os(v))throw v;return v},pr.times=function(e,t){if((e=Ys(e))<1||e>C)return[];var n=P,r=Xn(e,P);t=Io(t),e-=P;for(var a=pn(r,t);++n<e;)t(n);return a},pr.toFinite=Ws,pr.toInteger=Ys,pr.toLength=qs,pr.toLower=function(e){return Vs(e).toLowerCase()},pr.toNumber=Bs,pr.toSafeInteger=function(e){return e?Pr(Ys(e),-C,C):0===e?e:0},pr.toString=Vs,pr.toUpper=function(e){return Vs(e).toUpperCase()},pr.trim=function(e,t,r){if((e=Vs(e))&&(r||t===n))return e.replace(Ce,"");if(!e||!(t=Ia(t)))return e;var a=Tn(e),o=Tn(t);return Ga(a,bn(a,o),gn(a,o)+1).join("")},pr.trimEnd=function(e,t,r){if((e=Vs(e))&&(r||t===n))return e.replace(Ne,"");if(!e||!(t=Ia(t)))return e;var a=Tn(e);return Ga(a,0,gn(a,Tn(t))+1).join("")},pr.trimStart=function(e,t,r){if((e=Vs(e))&&(r||t===n))return e.replace(De,"");if(!e||!(t=Ia(t)))return e;var a=Tn(e);return Ga(a,bn(a,Tn(t))).join("")},pr.truncate=function(e,t){var r=w,a=k;if(Ss(t)){var o="separator"in t?t.separator:o;r="length"in t?Ys(t.length):r,a="omission"in t?Ia(t.omission):a}var i=(e=Vs(e)).length;if(En(e)){var s=Tn(e);i=s.length}if(r>=i)return e;var c=r-An(a);if(c<1)return a;var u=s?Ga(s,0,c).join(""):e.slice(0,c);if(o===n)return u+a;if(s&&(c+=u.length-c),Ds(o)){if(e.slice(c).search(o)){var l,d=u;for(o.global||(o=nt(o.source,Vs(We.exec(o))+"g")),o.lastIndex=0;l=o.exec(d);)var f=l.index;u=u.slice(0,f===n?c:f)}}else if(e.indexOf(Ia(o),c)!=c){var p=u.lastIndexOf(o);p>-1&&(u=u.slice(0,p))}return u+a},pr.unescape=function(e){return(e=Vs(e))&&Me.test(e)?e.replace(ye,zn):e},pr.uniqueId=function(e){var t=++dt;return Vs(e)+t},pr.upperCase=Ec,pr.upperFirst=Oc,pr.each=Vi,pr.eachRight=Xi,pr.first=yi,Pc(pr,(Gc={},Ur(pr,function(e,t){lt.call(pr.prototype,t)||(Gc[t]=e)}),Gc),{chain:!1}),pr.VERSION="4.17.15",Ft(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){pr[e].placeholder=pr}),Ft(["drop","take"],function(e,t){br.prototype[e]=function(r){r=r===n?1:Vn(Ys(r),0);var a=this.__filtered__&&!t?new br(this):this.clone();return a.__filtered__?a.__takeCount__=Xn(r,a.__takeCount__):a.__views__.push({size:Xn(r,P),type:e+(a.__dir__<0?"Right":"")}),a},br.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}}),Ft(["filter","map","takeWhile"],function(e,t){var n=t+1,r=n==A||3==n;br.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:Io(e,3),type:n}),t.__filtered__=t.__filtered__||r,t}}),Ft(["head","last"],function(e,t){var n="take"+(t?"Right":"");br.prototype[e]=function(){return this[n](1).value()[0]}}),Ft(["initial","tail"],function(e,t){var n="drop"+(t?"":"Right");br.prototype[e]=function(){return this.__filtered__?new br(this):this[n](1)}}),br.prototype.compact=function(){return this.filter(zc)},br.prototype.find=function(e){return this.filter(e).head()},br.prototype.findLast=function(e){return this.reverse().find(e)},br.prototype.invokeMap=Oa(function(e,t){return"function"==typeof e?new br(this):this.map(function(n){return ra(n,e,t)})}),br.prototype.reject=function(e){return this.filter(cs(Io(e)))},br.prototype.slice=function(e,t){e=Ys(e);var r=this;return r.__filtered__&&(e>0||t<0)?new br(r):(e<0?r=r.takeRight(-e):e&&(r=r.drop(e)),t!==n&&(r=(t=Ys(t))<0?r.dropRight(-t):r.take(t-e)),r)},br.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},br.prototype.toArray=function(){return this.take(P)},Ur(br.prototype,function(e,t){var r=/^(?:filter|find|map|reject)|While$/.test(t),a=/^(?:head|last)$/.test(t),o=pr[a?"take"+("last"==t?"Right":""):t],i=a||/^find/.test(t);o&&(pr.prototype[t]=function(){var t=this.__wrapped__,s=a?[1]:arguments,c=t instanceof br,u=s[0],l=c||bs(t),d=function(e){var t=o.apply(pr,$t([e],s));return a&&f?t[0]:t};l&&r&&"function"==typeof u&&1!=u.length&&(c=l=!1);var f=this.__chain__,p=!!this.__actions__.length,h=i&&!f,m=c&&!p;if(!i&&l){t=m?t:new br(this);var v=e.apply(t,s);return v.__actions__.push({func:Wi,args:[d],thisArg:n}),new vr(v,f)}return h&&m?e.apply(this,s):(v=this.thru(d),h?a?v.value()[0]:v.value():v)})}),Ft(["pop","push","shift","sort","splice","unshift"],function(e){var t=ot[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",r=/^(?:pop|shift)$/.test(e);pr.prototype[e]=function(){var e=arguments;if(r&&!this.__chain__){var a=this.value();return t.apply(bs(a)?a:[],e)}return this[n](function(n){return t.apply(bs(n)?n:[],e)})}}),Ur(br.prototype,function(e,t){var n=pr[t];if(n){var r=n.name+"";lt.call(ar,r)||(ar[r]=[]),ar[r].push({name:t,func:n})}}),ar[ho(n,m).name]=[{name:"wrapper",func:n}],br.prototype.clone=function(){var e=new br(this.__wrapped__);return e.__actions__=no(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=no(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=no(this.__views__),e},br.prototype.reverse=function(){if(this.__filtered__){var e=new br(this);e.__dir__=-1,e.__filtered__=!0}else(e=this.clone()).__dir__*=-1;return e},br.prototype.value=function(){var e=this.__wrapped__.value(),t=this.__dir__,n=bs(e),r=t<0,a=n?e.length:0,o=function(e,t,n){for(var r=-1,a=n.length;++r<a;){var o=n[r],i=o.size;switch(o.type){case"drop":e+=i;break;case"dropRight":t-=i;break;case"take":t=Xn(t,e+i);break;case"takeRight":e=Vn(e,t-i)}}return{start:e,end:t}}(0,a,this.__views__),i=o.start,s=o.end,c=s-i,u=r?s:i-1,l=this.__iteratees__,d=l.length,f=0,p=Xn(c,this.__takeCount__);if(!n||!r&&a==c&&p==c)return Ya(e,this.__actions__);var h=[];e:for(;c--&&f<p;){for(var m=-1,v=e[u+=t];++m<d;){var b=l[m],g=b.iteratee,y=b.type,_=g(v);if(y==T)v=_;else if(!_){if(y==A)continue e;break e}}h[f++]=v}return h},pr.prototype.at=Yi,pr.prototype.chain=function(){return Hi(this)},pr.prototype.commit=function(){return new vr(this.value(),this.__chain__)},pr.prototype.next=function(){this.__values__===n&&(this.__values__=Hs(this.value()));var e=this.__index__>=this.__values__.length;return{done:e,value:e?n:this.__values__[this.__index__++]}},pr.prototype.plant=function(e){for(var t,r=this;r instanceof mr;){var a=fi(r);a.__index__=0,a.__values__=n,t?o.__wrapped__=a:t=a;var o=a;r=r.__wrapped__}return o.__wrapped__=e,t},pr.prototype.reverse=function(){var e=this.__wrapped__;if(e instanceof br){var t=e;return this.__actions__.length&&(t=new br(this)),(t=t.reverse()).__actions__.push({func:Wi,args:[Si],thisArg:n}),new vr(t,this.__chain__)}return this.thru(Si)},pr.prototype.toJSON=pr.prototype.valueOf=pr.prototype.value=function(){return Ya(this.__wrapped__,this.__actions__)},pr.prototype.first=pr.prototype.head,Dn&&(pr.prototype[Dn]=function(){return this}),pr}();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(zt._=Cn,define(function(){return Cn})):Dt?((Dt.exports=Cn)._=Cn,Ct._=Cn):zt._=Cn}).call(this)}).call(this,n(303)(e))},function(e,t,n){e.exports=n(622)()},function(e,t){e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}},function(e,t,n){var r=n(3);e.exports=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),a.forEach(function(t){r(e,t,n[t])})}return e}},function(e,t,n){var r=n(633),a=new r;e.exports={moment:a.moment,numberFormat:a.numberFormat.bind(a),translate:a.translate.bind(a),configure:a.configure.bind(a),setLocale:a.setLocale.bind(a),getLocale:a.getLocale.bind(a),getLocaleSlug:a.getLocaleSlug.bind(a),addTranslations:a.addTranslations.bind(a),reRenderTranslations:a.reRenderTranslations.bind(a),registerComponentUpdateHook:a.registerComponentUpdateHook.bind(a),registerTranslateHook:a.registerTranslateHook.bind(a),state:a.state,stateObserver:a.stateObserver,on:a.stateObserver.on.bind(a.stateObserver),off:a.stateObserver.removeListener.bind(a.stateObserver),emit:a.stateObserver.emit.bind(a.stateObserver),mixin:n(652)(a),localize:n(655)(a),$this:a,I18N:r}},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}},function(e,t){
2
+ /*!
3
+ Copyright (c) 2017 Jed Watson.
4
+ Licensed under the MIT License (MIT), see
5
+ http://jedwatson.github.io/classnames
6
+ */
7
+ !function(){"use strict";var t={}.hasOwnProperty;function n(){for(var e=[],r=0;r<arguments.length;r++){var a=arguments[r];if(a){var o=typeof a;if("string"===o||"number"===o)e.push(a);else if(Array.isArray(a)&&a.length){var i=n.apply(null,a);i&&e.push(i)}else if("object"===o)for(var s in a)t.call(a,s)&&a[s]&&e.push(s)}}return e.join(" ")}void 0!==e&&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}()},function(e,t,n){(function(e){e.exports=function(){"use strict";var t,r;function a(){return t.apply(null,arguments)}function o(e){return e instanceof Array||"[object Array]"===Object.prototype.toString.call(e)}function i(e){return null!=e&&"[object Object]"===Object.prototype.toString.call(e)}function s(e){return void 0===e}function c(e){return"number"==typeof e||"[object Number]"===Object.prototype.toString.call(e)}function u(e){return e instanceof Date||"[object Date]"===Object.prototype.toString.call(e)}function l(e,t){var n,r=[];for(n=0;n<e.length;++n)r.push(t(e[n],n));return r}function d(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function f(e,t){for(var n in t)d(t,n)&&(e[n]=t[n]);return d(t,"toString")&&(e.toString=t.toString),d(t,"valueOf")&&(e.valueOf=t.valueOf),e}function p(e,t,n,r){return zt(e,t,n,r,!0).utc()}function h(e){return null==e._pf&&(e._pf={empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],meridiem:null,rfc2822:!1,weekdayMismatch:!1}),e._pf}function m(e){if(null==e._isValid){var t=h(e),n=r.call(t.parsedDateParts,function(e){return null!=e}),a=!isNaN(e._d.getTime())&&t.overflow<0&&!t.empty&&!t.invalidMonth&&!t.invalidWeekday&&!t.weekdayMismatch&&!t.nullInput&&!t.invalidFormat&&!t.userInvalidated&&(!t.meridiem||t.meridiem&&n);if(e._strict&&(a=a&&0===t.charsLeftOver&&0===t.unusedTokens.length&&void 0===t.bigHour),null!=Object.isFrozen&&Object.isFrozen(e))return a;e._isValid=a}return e._isValid}function v(e){var t=p(NaN);return null!=e?f(h(t),e):h(t).userInvalidated=!0,t}r=Array.prototype.some?Array.prototype.some:function(e){for(var t=Object(this),n=t.length>>>0,r=0;r<n;r++)if(r in t&&e.call(this,t[r],r,t))return!0;return!1};var b=a.momentProperties=[];function g(e,t){var n,r,a;if(s(t._isAMomentObject)||(e._isAMomentObject=t._isAMomentObject),s(t._i)||(e._i=t._i),s(t._f)||(e._f=t._f),s(t._l)||(e._l=t._l),s(t._strict)||(e._strict=t._strict),s(t._tzm)||(e._tzm=t._tzm),s(t._isUTC)||(e._isUTC=t._isUTC),s(t._offset)||(e._offset=t._offset),s(t._pf)||(e._pf=h(t)),s(t._locale)||(e._locale=t._locale),b.length>0)for(n=0;n<b.length;n++)r=b[n],s(a=t[r])||(e[r]=a);return e}var y=!1;function _(e){g(this,e),this._d=new Date(null!=e._d?e._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),!1===y&&(y=!0,a.updateOffset(this),y=!1)}function M(e){return e instanceof _||null!=e&&null!=e._isAMomentObject}function E(e){return e<0?Math.ceil(e)||0:Math.floor(e)}function O(e){var t=+e,n=0;return 0!==t&&isFinite(t)&&(n=E(t)),n}function w(e,t,n){var r,a=Math.min(e.length,t.length),o=Math.abs(e.length-t.length),i=0;for(r=0;r<a;r++)(n&&e[r]!==t[r]||!n&&O(e[r])!==O(t[r]))&&i++;return i+o}function k(e){!1===a.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+e)}function L(e,t){var n=!0;return f(function(){if(null!=a.deprecationHandler&&a.deprecationHandler(null,e),n){for(var r,o=[],i=0;i<arguments.length;i++){if(r="","object"==typeof arguments[i]){for(var s in r+="\n["+i+"] ",arguments[0])r+=s+": "+arguments[0][s]+", ";r=r.slice(0,-2)}else r=arguments[i];o.push(r)}k(e+"\nArguments: "+Array.prototype.slice.call(o).join("")+"\n"+(new Error).stack),n=!1}return t.apply(this,arguments)},t)}var S,A={};function T(e,t){null!=a.deprecationHandler&&a.deprecationHandler(e,t),A[e]||(k(t),A[e]=!0)}function z(e){return e instanceof Function||"[object Function]"===Object.prototype.toString.call(e)}function C(e,t){var n,r=f({},e);for(n in t)d(t,n)&&(i(e[n])&&i(t[n])?(r[n]={},f(r[n],e[n]),f(r[n],t[n])):null!=t[n]?r[n]=t[n]:delete r[n]);for(n in e)d(e,n)&&!d(t,n)&&i(e[n])&&(r[n]=f({},r[n]));return r}function D(e){null!=e&&this.set(e)}a.suppressDeprecationWarnings=!1,a.deprecationHandler=null,S=Object.keys?Object.keys:function(e){var t,n=[];for(t in e)d(e,t)&&n.push(t);return n};var N={};function P(e,t){var n=e.toLowerCase();N[n]=N[n+"s"]=N[t]=e}function x(e){return"string"==typeof e?N[e]||N[e.toLowerCase()]:void 0}function I(e){var t,n,r={};for(n in e)d(e,n)&&(t=x(n))&&(r[t]=e[n]);return r}var R={};function j(e,t){R[e]=t}function H(e,t,n){var r=""+Math.abs(e),a=t-r.length,o=e>=0;return(o?n?"+":"":"-")+Math.pow(10,Math.max(0,a)).toString().substr(1)+r}var W=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Y=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,q={},B={};function F(e,t,n,r){var a=r;"string"==typeof r&&(a=function(){return this[r]()}),e&&(B[e]=a),t&&(B[t[0]]=function(){return H(a.apply(this,arguments),t[1],t[2])}),n&&(B[n]=function(){return this.localeData().ordinal(a.apply(this,arguments),e)})}function V(e,t){return e.isValid()?(t=X(t,e.localeData()),q[t]=q[t]||function(e){var t,n,r,a=e.match(W);for(t=0,n=a.length;t<n;t++)B[a[t]]?a[t]=B[a[t]]:a[t]=(r=a[t]).match(/\[[\s\S]/)?r.replace(/^\[|\]$/g,""):r.replace(/\\/g,"");return function(t){var r,o="";for(r=0;r<n;r++)o+=z(a[r])?a[r].call(t,e):a[r];return o}}(t),q[t](e)):e.localeData().invalidDate()}function X(e,t){var n=5;function r(e){return t.longDateFormat(e)||e}for(Y.lastIndex=0;n>=0&&Y.test(e);)e=e.replace(Y,r),Y.lastIndex=0,n-=1;return e}var U=/\d/,G=/\d\d/,K=/\d{3}/,J=/\d{4}/,$=/[+-]?\d{6}/,Q=/\d\d?/,Z=/\d\d\d\d?/,ee=/\d\d\d\d\d\d?/,te=/\d{1,3}/,ne=/\d{1,4}/,re=/[+-]?\d{1,6}/,ae=/\d+/,oe=/[+-]?\d+/,ie=/Z|[+-]\d\d:?\d\d/gi,se=/Z|[+-]\d\d(?::?\d\d)?/gi,ce=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,ue={};function le(e,t,n){ue[e]=z(t)?t:function(e,r){return e&&n?n:t}}function de(e,t){return d(ue,e)?ue[e](t._strict,t._locale):new RegExp(fe(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(e,t,n,r,a){return t||n||r||a})))}function fe(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}var pe={};function he(e,t){var n,r=t;for("string"==typeof e&&(e=[e]),c(t)&&(r=function(e,n){n[t]=O(e)}),n=0;n<e.length;n++)pe[e[n]]=r}function me(e,t){he(e,function(e,n,r,a){r._w=r._w||{},t(e,r._w,r,a)})}function ve(e,t,n){null!=t&&d(pe,e)&&pe[e](t,n._a,n,e)}var be=0,ge=1,ye=2,_e=3,Me=4,Ee=5,Oe=6,we=7,ke=8;function Le(e){return Se(e)?366:365}function Se(e){return e%4==0&&e%100!=0||e%400==0}F("Y",0,0,function(){var e=this.year();return e<=9999?""+e:"+"+e}),F(0,["YY",2],0,function(){return this.year()%100}),F(0,["YYYY",4],0,"year"),F(0,["YYYYY",5],0,"year"),F(0,["YYYYYY",6,!0],0,"year"),P("year","y"),j("year",1),le("Y",oe),le("YY",Q,G),le("YYYY",ne,J),le("YYYYY",re,$),le("YYYYYY",re,$),he(["YYYYY","YYYYYY"],be),he("YYYY",function(e,t){t[be]=2===e.length?a.parseTwoDigitYear(e):O(e)}),he("YY",function(e,t){t[be]=a.parseTwoDigitYear(e)}),he("Y",function(e,t){t[be]=parseInt(e,10)}),a.parseTwoDigitYear=function(e){return O(e)+(O(e)>68?1900:2e3)};var Ae,Te=ze("FullYear",!0);function ze(e,t){return function(n){return null!=n?(De(this,e,n),a.updateOffset(this,t),this):Ce(this,e)}}function Ce(e,t){return e.isValid()?e._d["get"+(e._isUTC?"UTC":"")+t]():NaN}function De(e,t,n){e.isValid()&&!isNaN(n)&&("FullYear"===t&&Se(e.year())&&1===e.month()&&29===e.date()?e._d["set"+(e._isUTC?"UTC":"")+t](n,e.month(),Ne(n,e.month())):e._d["set"+(e._isUTC?"UTC":"")+t](n))}function Ne(e,t){if(isNaN(e)||isNaN(t))return NaN;var n,r=(t%(n=12)+n)%n;return e+=(t-r)/12,1===r?Se(e)?29:28:31-r%7%2}Ae=Array.prototype.indexOf?Array.prototype.indexOf:function(e){var t;for(t=0;t<this.length;++t)if(this[t]===e)return t;return-1},F("M",["MM",2],"Mo",function(){return this.month()+1}),F("MMM",0,0,function(e){return this.localeData().monthsShort(this,e)}),F("MMMM",0,0,function(e){return this.localeData().months(this,e)}),P("month","M"),j("month",8),le("M",Q),le("MM",Q,G),le("MMM",function(e,t){return t.monthsShortRegex(e)}),le("MMMM",function(e,t){return t.monthsRegex(e)}),he(["M","MM"],function(e,t){t[ge]=O(e)-1}),he(["MMM","MMMM"],function(e,t,n,r){var a=n._locale.monthsParse(e,r,n._strict);null!=a?t[ge]=a:h(n).invalidMonth=e});var Pe=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,xe="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Ie="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_");function Re(e,t){var n;if(!e.isValid())return e;if("string"==typeof t)if(/^\d+$/.test(t))t=O(t);else if(!c(t=e.localeData().monthsParse(t)))return e;return n=Math.min(e.date(),Ne(e.year(),t)),e._d["set"+(e._isUTC?"UTC":"")+"Month"](t,n),e}function je(e){return null!=e?(Re(this,e),a.updateOffset(this,!0),this):Ce(this,"Month")}var He=ce,We=ce;function Ye(){function e(e,t){return t.length-e.length}var t,n,r=[],a=[],o=[];for(t=0;t<12;t++)n=p([2e3,t]),r.push(this.monthsShort(n,"")),a.push(this.months(n,"")),o.push(this.months(n,"")),o.push(this.monthsShort(n,""));for(r.sort(e),a.sort(e),o.sort(e),t=0;t<12;t++)r[t]=fe(r[t]),a[t]=fe(a[t]);for(t=0;t<24;t++)o[t]=fe(o[t]);this._monthsRegex=new RegExp("^("+o.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+a.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+r.join("|")+")","i")}function qe(e){var t;if(e<100&&e>=0){var n=Array.prototype.slice.call(arguments);n[0]=e+400,t=new Date(Date.UTC.apply(null,n)),isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e)}else t=new Date(Date.UTC.apply(null,arguments));return t}function Be(e,t,n){var r=7+t-n,a=(7+qe(e,0,r).getUTCDay()-t)%7;return-a+r-1}function Fe(e,t,n,r,a){var o,i,s=(7+n-r)%7,c=Be(e,r,a),u=1+7*(t-1)+s+c;return u<=0?i=Le(o=e-1)+u:u>Le(e)?(o=e+1,i=u-Le(e)):(o=e,i=u),{year:o,dayOfYear:i}}function Ve(e,t,n){var r,a,o=Be(e.year(),t,n),i=Math.floor((e.dayOfYear()-o-1)/7)+1;return i<1?(a=e.year()-1,r=i+Xe(a,t,n)):i>Xe(e.year(),t,n)?(r=i-Xe(e.year(),t,n),a=e.year()+1):(a=e.year(),r=i),{week:r,year:a}}function Xe(e,t,n){var r=Be(e,t,n),a=Be(e+1,t,n);return(Le(e)-r+a)/7}function Ue(e,t){return e.slice(t,7).concat(e.slice(0,t))}F("w",["ww",2],"wo","week"),F("W",["WW",2],"Wo","isoWeek"),P("week","w"),P("isoWeek","W"),j("week",5),j("isoWeek",5),le("w",Q),le("ww",Q,G),le("W",Q),le("WW",Q,G),me(["w","ww","W","WW"],function(e,t,n,r){t[r.substr(0,1)]=O(e)}),F("d",0,"do","day"),F("dd",0,0,function(e){return this.localeData().weekdaysMin(this,e)}),F("ddd",0,0,function(e){return this.localeData().weekdaysShort(this,e)}),F("dddd",0,0,function(e){return this.localeData().weekdays(this,e)}),F("e",0,0,"weekday"),F("E",0,0,"isoWeekday"),P("day","d"),P("weekday","e"),P("isoWeekday","E"),j("day",11),j("weekday",11),j("isoWeekday",11),le("d",Q),le("e",Q),le("E",Q),le("dd",function(e,t){return t.weekdaysMinRegex(e)}),le("ddd",function(e,t){return t.weekdaysShortRegex(e)}),le("dddd",function(e,t){return t.weekdaysRegex(e)}),me(["dd","ddd","dddd"],function(e,t,n,r){var a=n._locale.weekdaysParse(e,r,n._strict);null!=a?t.d=a:h(n).invalidWeekday=e}),me(["d","e","E"],function(e,t,n,r){t[r]=O(e)});var Ge="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Ke="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Je="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),$e=ce,Qe=ce,Ze=ce;function et(){function e(e,t){return t.length-e.length}var t,n,r,a,o,i=[],s=[],c=[],u=[];for(t=0;t<7;t++)n=p([2e3,1]).day(t),r=this.weekdaysMin(n,""),a=this.weekdaysShort(n,""),o=this.weekdays(n,""),i.push(r),s.push(a),c.push(o),u.push(r),u.push(a),u.push(o);for(i.sort(e),s.sort(e),c.sort(e),u.sort(e),t=0;t<7;t++)s[t]=fe(s[t]),c[t]=fe(c[t]),u[t]=fe(u[t]);this._weekdaysRegex=new RegExp("^("+u.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+c.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+i.join("|")+")","i")}function tt(){return this.hours()%12||12}function nt(e,t){F(e,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)})}function rt(e,t){return t._meridiemParse}F("H",["HH",2],0,"hour"),F("h",["hh",2],0,tt),F("k",["kk",2],0,function(){return this.hours()||24}),F("hmm",0,0,function(){return""+tt.apply(this)+H(this.minutes(),2)}),F("hmmss",0,0,function(){return""+tt.apply(this)+H(this.minutes(),2)+H(this.seconds(),2)}),F("Hmm",0,0,function(){return""+this.hours()+H(this.minutes(),2)}),F("Hmmss",0,0,function(){return""+this.hours()+H(this.minutes(),2)+H(this.seconds(),2)}),nt("a",!0),nt("A",!1),P("hour","h"),j("hour",13),le("a",rt),le("A",rt),le("H",Q),le("h",Q),le("k",Q),le("HH",Q,G),le("hh",Q,G),le("kk",Q,G),le("hmm",Z),le("hmmss",ee),le("Hmm",Z),le("Hmmss",ee),he(["H","HH"],_e),he(["k","kk"],function(e,t,n){var r=O(e);t[_e]=24===r?0:r}),he(["a","A"],function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e}),he(["h","hh"],function(e,t,n){t[_e]=O(e),h(n).bigHour=!0}),he("hmm",function(e,t,n){var r=e.length-2;t[_e]=O(e.substr(0,r)),t[Me]=O(e.substr(r)),h(n).bigHour=!0}),he("hmmss",function(e,t,n){var r=e.length-4,a=e.length-2;t[_e]=O(e.substr(0,r)),t[Me]=O(e.substr(r,2)),t[Ee]=O(e.substr(a)),h(n).bigHour=!0}),he("Hmm",function(e,t,n){var r=e.length-2;t[_e]=O(e.substr(0,r)),t[Me]=O(e.substr(r))}),he("Hmmss",function(e,t,n){var r=e.length-4,a=e.length-2;t[_e]=O(e.substr(0,r)),t[Me]=O(e.substr(r,2)),t[Ee]=O(e.substr(a))});var at,ot=ze("Hours",!0),it={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},longDateFormat:{LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:xe,monthsShort:Ie,week:{dow:0,doy:6},weekdays:Ge,weekdaysMin:Je,weekdaysShort:Ke,meridiemParse:/[ap]\.?m?\.?/i},st={},ct={};function ut(e){return e?e.toLowerCase().replace("_","-"):e}function lt(t){var r=null;if(!st[t]&&void 0!==e&&e&&e.exports)try{r=at._abbr,n(639)("./"+t),dt(r)}catch(a){}return st[t]}function dt(e,t){var n;return e&&((n=s(t)?pt(e):ft(e,t))?at=n:"undefined"!=typeof console&&console.warn&&console.warn("Locale "+e+" not found. Did you forget to load it?")),at._abbr}function ft(e,t){if(null!==t){var n,r=it;if(t.abbr=e,null!=st[e])T("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),r=st[e]._config;else if(null!=t.parentLocale)if(null!=st[t.parentLocale])r=st[t.parentLocale]._config;else{if(null==(n=lt(t.parentLocale)))return ct[t.parentLocale]||(ct[t.parentLocale]=[]),ct[t.parentLocale].push({name:e,config:t}),null;r=n._config}return st[e]=new D(C(r,t)),ct[e]&&ct[e].forEach(function(e){ft(e.name,e.config)}),dt(e),st[e]}return delete st[e],null}function pt(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return at;if(!o(e)){if(t=lt(e))return t;e=[e]}return function(e){for(var t,n,r,a,o=0;o<e.length;){for(a=ut(e[o]).split("-"),t=a.length,n=(n=ut(e[o+1]))?n.split("-"):null;t>0;){if(r=lt(a.slice(0,t).join("-")))return r;if(n&&n.length>=t&&w(a,n,!0)>=t-1)break;t--}o++}return at}(e)}function ht(e){var t,n=e._a;return n&&-2===h(e).overflow&&(t=n[ge]<0||n[ge]>11?ge:n[ye]<1||n[ye]>Ne(n[be],n[ge])?ye:n[_e]<0||n[_e]>24||24===n[_e]&&(0!==n[Me]||0!==n[Ee]||0!==n[Oe])?_e:n[Me]<0||n[Me]>59?Me:n[Ee]<0||n[Ee]>59?Ee:n[Oe]<0||n[Oe]>999?Oe:-1,h(e)._overflowDayOfYear&&(t<be||t>ye)&&(t=ye),h(e)._overflowWeeks&&-1===t&&(t=we),h(e)._overflowWeekday&&-1===t&&(t=ke),h(e).overflow=t),e}function mt(e,t,n){return null!=e?e:null!=t?t:n}function vt(e){var t,n,r,o,i,s=[];if(!e._d){for(r=function(e){var t=new Date(a.now());return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}(e),e._w&&null==e._a[ye]&&null==e._a[ge]&&function(e){var t,n,r,a,o,i,s,c;if(null!=(t=e._w).GG||null!=t.W||null!=t.E)o=1,i=4,n=mt(t.GG,e._a[be],Ve(Ct(),1,4).year),r=mt(t.W,1),((a=mt(t.E,1))<1||a>7)&&(c=!0);else{o=e._locale._week.dow,i=e._locale._week.doy;var u=Ve(Ct(),o,i);n=mt(t.gg,e._a[be],u.year),r=mt(t.w,u.week),null!=t.d?((a=t.d)<0||a>6)&&(c=!0):null!=t.e?(a=t.e+o,(t.e<0||t.e>6)&&(c=!0)):a=o}r<1||r>Xe(n,o,i)?h(e)._overflowWeeks=!0:null!=c?h(e)._overflowWeekday=!0:(s=Fe(n,r,a,o,i),e._a[be]=s.year,e._dayOfYear=s.dayOfYear)}(e),null!=e._dayOfYear&&(i=mt(e._a[be],r[be]),(e._dayOfYear>Le(i)||0===e._dayOfYear)&&(h(e)._overflowDayOfYear=!0),n=qe(i,0,e._dayOfYear),e._a[ge]=n.getUTCMonth(),e._a[ye]=n.getUTCDate()),t=0;t<3&&null==e._a[t];++t)e._a[t]=s[t]=r[t];for(;t<7;t++)e._a[t]=s[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[_e]&&0===e._a[Me]&&0===e._a[Ee]&&0===e._a[Oe]&&(e._nextDay=!0,e._a[_e]=0),e._d=(e._useUTC?qe:function(e,t,n,r,a,o,i){var s;return e<100&&e>=0?(s=new Date(e+400,t,n,r,a,o,i),isFinite(s.getFullYear())&&s.setFullYear(e)):s=new Date(e,t,n,r,a,o,i),s}).apply(null,s),o=e._useUTC?e._d.getUTCDay():e._d.getDay(),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[_e]=24),e._w&&void 0!==e._w.d&&e._w.d!==o&&(h(e).weekdayMismatch=!0)}}var bt=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,gt=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,yt=/Z|[+-]\d\d(?::?\d\d)?/,_t=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/]],Mt=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],Et=/^\/?Date\((\-?\d+)/i;function Ot(e){var t,n,r,a,o,i,s=e._i,c=bt.exec(s)||gt.exec(s);if(c){for(h(e).iso=!0,t=0,n=_t.length;t<n;t++)if(_t[t][1].exec(c[1])){a=_t[t][0],r=!1!==_t[t][2];break}if(null==a)return void(e._isValid=!1);if(c[3]){for(t=0,n=Mt.length;t<n;t++)if(Mt[t][1].exec(c[3])){o=(c[2]||" ")+Mt[t][0];break}if(null==o)return void(e._isValid=!1)}if(!r&&null!=o)return void(e._isValid=!1);if(c[4]){if(!yt.exec(c[4]))return void(e._isValid=!1);i="Z"}e._f=a+(o||"")+(i||""),At(e)}else e._isValid=!1}var wt=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/;function kt(e){var t=parseInt(e,10);return t<=49?2e3+t:t<=999?1900+t:t}var Lt={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function St(e){var t,n,r,a,o,i,s,c=wt.exec(e._i.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,""));if(c){var u=(t=c[4],n=c[3],r=c[2],a=c[5],o=c[6],i=c[7],s=[kt(t),Ie.indexOf(n),parseInt(r,10),parseInt(a,10),parseInt(o,10)],i&&s.push(parseInt(i,10)),s);if(!function(e,t,n){if(e){var r=Ke.indexOf(e),a=new Date(t[0],t[1],t[2]).getDay();if(r!==a)return h(n).weekdayMismatch=!0,n._isValid=!1,!1}return!0}(c[1],u,e))return;e._a=u,e._tzm=function(e,t,n){if(e)return Lt[e];if(t)return 0;var r=parseInt(n,10),a=r%100,o=(r-a)/100;return 60*o+a}(c[8],c[9],c[10]),e._d=qe.apply(null,e._a),e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),h(e).rfc2822=!0}else e._isValid=!1}function At(e){if(e._f!==a.ISO_8601)if(e._f!==a.RFC_2822){e._a=[],h(e).empty=!0;var t,n,r,o,i,s=""+e._i,c=s.length,u=0;for(r=X(e._f,e._locale).match(W)||[],t=0;t<r.length;t++)o=r[t],(n=(s.match(de(o,e))||[])[0])&&((i=s.substr(0,s.indexOf(n))).length>0&&h(e).unusedInput.push(i),s=s.slice(s.indexOf(n)+n.length),u+=n.length),B[o]?(n?h(e).empty=!1:h(e).unusedTokens.push(o),ve(o,n,e)):e._strict&&!n&&h(e).unusedTokens.push(o);h(e).charsLeftOver=c-u,s.length>0&&h(e).unusedInput.push(s),e._a[_e]<=12&&!0===h(e).bigHour&&e._a[_e]>0&&(h(e).bigHour=void 0),h(e).parsedDateParts=e._a.slice(0),h(e).meridiem=e._meridiem,e._a[_e]=(l=e._locale,d=e._a[_e],null==(f=e._meridiem)?d:null!=l.meridiemHour?l.meridiemHour(d,f):null!=l.isPM?((p=l.isPM(f))&&d<12&&(d+=12),p||12!==d||(d=0),d):d),vt(e),ht(e)}else St(e);else Ot(e);var l,d,f,p}function Tt(e){var t=e._i,n=e._f;return e._locale=e._locale||pt(e._l),null===t||void 0===n&&""===t?v({nullInput:!0}):("string"==typeof t&&(e._i=t=e._locale.preparse(t)),M(t)?new _(ht(t)):(u(t)?e._d=t:o(n)?function(e){var t,n,r,a,o;if(0===e._f.length)return h(e).invalidFormat=!0,void(e._d=new Date(NaN));for(a=0;a<e._f.length;a++)o=0,t=g({},e),null!=e._useUTC&&(t._useUTC=e._useUTC),t._f=e._f[a],At(t),m(t)&&(o+=h(t).charsLeftOver,o+=10*h(t).unusedTokens.length,h(t).score=o,(null==r||o<r)&&(r=o,n=t));f(e,n||t)}(e):n?At(e):function(e){var t=e._i;s(t)?e._d=new Date(a.now()):u(t)?e._d=new Date(t.valueOf()):"string"==typeof t?function(e){var t=Et.exec(e._i);null===t?(Ot(e),!1===e._isValid&&(delete e._isValid,St(e),!1===e._isValid&&(delete e._isValid,a.createFromInputFallback(e)))):e._d=new Date(+t[1])}(e):o(t)?(e._a=l(t.slice(0),function(e){return parseInt(e,10)}),vt(e)):i(t)?function(e){if(!e._d){var t=I(e._i);e._a=l([t.year,t.month,t.day||t.date,t.hour,t.minute,t.second,t.millisecond],function(e){return e&&parseInt(e,10)}),vt(e)}}(e):c(t)?e._d=new Date(t):a.createFromInputFallback(e)}(e),m(e)||(e._d=null),e))}function zt(e,t,n,r,a){var s,c={};return!0!==n&&!1!==n||(r=n,n=void 0),(i(e)&&function(e){if(Object.getOwnPropertyNames)return 0===Object.getOwnPropertyNames(e).length;var t;for(t in e)if(e.hasOwnProperty(t))return!1;return!0}(e)||o(e)&&0===e.length)&&(e=void 0),c._isAMomentObject=!0,c._useUTC=c._isUTC=a,c._l=n,c._i=e,c._f=t,c._strict=r,(s=new _(ht(Tt(c))))._nextDay&&(s.add(1,"d"),s._nextDay=void 0),s}function Ct(e,t,n,r){return zt(e,t,n,r,!1)}a.createFromInputFallback=L("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged and will be removed in an upcoming major release. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))}),a.ISO_8601=function(){},a.RFC_2822=function(){};var Dt=L("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=Ct.apply(null,arguments);return this.isValid()&&e.isValid()?e<this?this:e:v()}),Nt=L("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=Ct.apply(null,arguments);return this.isValid()&&e.isValid()?e>this?this:e:v()});function Pt(e,t){var n,r;if(1===t.length&&o(t[0])&&(t=t[0]),!t.length)return Ct();for(n=t[0],r=1;r<t.length;++r)t[r].isValid()&&!t[r][e](n)||(n=t[r]);return n}var xt=["year","quarter","month","week","day","hour","minute","second","millisecond"];function It(e){var t=I(e),n=t.year||0,r=t.quarter||0,a=t.month||0,o=t.week||t.isoWeek||0,i=t.day||0,s=t.hour||0,c=t.minute||0,u=t.second||0,l=t.millisecond||0;this._isValid=function(e){for(var t in e)if(-1===Ae.call(xt,t)||null!=e[t]&&isNaN(e[t]))return!1;for(var n=!1,r=0;r<xt.length;++r)if(e[xt[r]]){if(n)return!1;parseFloat(e[xt[r]])!==O(e[xt[r]])&&(n=!0)}return!0}(t),this._milliseconds=+l+1e3*u+6e4*c+1e3*s*60*60,this._days=+i+7*o,this._months=+a+3*r+12*n,this._data={},this._locale=pt(),this._bubble()}function Rt(e){return e instanceof It}function jt(e){return e<0?-1*Math.round(-1*e):Math.round(e)}function Ht(e,t){F(e,0,0,function(){var e=this.utcOffset(),n="+";return e<0&&(e=-e,n="-"),n+H(~~(e/60),2)+t+H(~~e%60,2)})}Ht("Z",":"),Ht("ZZ",""),le("Z",se),le("ZZ",se),he(["Z","ZZ"],function(e,t,n){n._useUTC=!0,n._tzm=Yt(se,e)});var Wt=/([\+\-]|\d\d)/gi;function Yt(e,t){var n=(t||"").match(e);if(null===n)return null;var r=n[n.length-1]||[],a=(r+"").match(Wt)||["-",0,0],o=60*a[1]+O(a[2]);return 0===o?0:"+"===a[0]?o:-o}function qt(e,t){var n,r;return t._isUTC?(n=t.clone(),r=(M(e)||u(e)?e.valueOf():Ct(e).valueOf())-n.valueOf(),n._d.setTime(n._d.valueOf()+r),a.updateOffset(n,!1),n):Ct(e).local()}function Bt(e){return 15*-Math.round(e._d.getTimezoneOffset()/15)}function Ft(){return!!this.isValid()&&this._isUTC&&0===this._offset}a.updateOffset=function(){};var Vt=/^(\-|\+)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)(\.\d*)?)?$/,Xt=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function Ut(e,t){var n,r,a,o,i,s,u=e,l=null;return Rt(e)?u={ms:e._milliseconds,d:e._days,M:e._months}:c(e)?(u={},t?u[t]=e:u.milliseconds=e):(l=Vt.exec(e))?(n="-"===l[1]?-1:1,u={y:0,d:O(l[ye])*n,h:O(l[_e])*n,m:O(l[Me])*n,s:O(l[Ee])*n,ms:O(jt(1e3*l[Oe]))*n}):(l=Xt.exec(e))?(n="-"===l[1]?-1:1,u={y:Gt(l[2],n),M:Gt(l[3],n),w:Gt(l[4],n),d:Gt(l[5],n),h:Gt(l[6],n),m:Gt(l[7],n),s:Gt(l[8],n)}):null==u?u={}:"object"==typeof u&&("from"in u||"to"in u)&&(o=Ct(u.from),i=Ct(u.to),a=o.isValid()&&i.isValid()?(i=qt(i,o),o.isBefore(i)?s=Kt(o,i):((s=Kt(i,o)).milliseconds=-s.milliseconds,s.months=-s.months),s):{milliseconds:0,months:0},(u={}).ms=a.milliseconds,u.M=a.months),r=new It(u),Rt(e)&&d(e,"_locale")&&(r._locale=e._locale),r}function Gt(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function Kt(e,t){var n={};return n.months=t.month()-e.month()+12*(t.year()-e.year()),e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function Jt(e,t){return function(n,r){var a;return null===r||isNaN(+r)||(T(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),a=n,n=r,r=a),$t(this,Ut(n="string"==typeof n?+n:n,r),e),this}}function $t(e,t,n,r){var o=t._milliseconds,i=jt(t._days),s=jt(t._months);e.isValid()&&(r=null==r||r,s&&Re(e,Ce(e,"Month")+s*n),i&&De(e,"Date",Ce(e,"Date")+i*n),o&&e._d.setTime(e._d.valueOf()+o*n),r&&a.updateOffset(e,i||s))}Ut.fn=It.prototype,Ut.invalid=function(){return Ut(NaN)};var Qt=Jt(1,"add"),Zt=Jt(-1,"subtract");function en(e,t){var n,r,a=12*(t.year()-e.year())+(t.month()-e.month()),o=e.clone().add(a,"months");return t-o<0?(n=e.clone().add(a-1,"months"),r=(t-o)/(o-n)):(n=e.clone().add(a+1,"months"),r=(t-o)/(n-o)),-(a+r)||0}function tn(e){var t;return void 0===e?this._locale._abbr:(null!=(t=pt(e))&&(this._locale=t),this)}a.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",a.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var nn=L("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(e){return void 0===e?this.localeData():this.locale(e)});function rn(){return this._locale}var an=1e3,on=60*an,sn=60*on,cn=3506328*sn;function un(e,t){return(e%t+t)%t}function ln(e,t,n){return e<100&&e>=0?new Date(e+400,t,n)-cn:new Date(e,t,n).valueOf()}function dn(e,t,n){return e<100&&e>=0?Date.UTC(e+400,t,n)-cn:Date.UTC(e,t,n)}function fn(e,t){F(0,[e,e.length],0,t)}function pn(e,t,n,r,a){var o;return null==e?Ve(this,r,a).year:(o=Xe(e,r,a),t>o&&(t=o),function(e,t,n,r,a){var o=Fe(e,t,n,r,a),i=qe(o.year,0,o.dayOfYear);return this.year(i.getUTCFullYear()),this.month(i.getUTCMonth()),this.date(i.getUTCDate()),this}.call(this,e,t,n,r,a))}F(0,["gg",2],0,function(){return this.weekYear()%100}),F(0,["GG",2],0,function(){return this.isoWeekYear()%100}),fn("gggg","weekYear"),fn("ggggg","weekYear"),fn("GGGG","isoWeekYear"),fn("GGGGG","isoWeekYear"),P("weekYear","gg"),P("isoWeekYear","GG"),j("weekYear",1),j("isoWeekYear",1),le("G",oe),le("g",oe),le("GG",Q,G),le("gg",Q,G),le("GGGG",ne,J),le("gggg",ne,J),le("GGGGG",re,$),le("ggggg",re,$),me(["gggg","ggggg","GGGG","GGGGG"],function(e,t,n,r){t[r.substr(0,2)]=O(e)}),me(["gg","GG"],function(e,t,n,r){t[r]=a.parseTwoDigitYear(e)}),F("Q",0,"Qo","quarter"),P("quarter","Q"),j("quarter",7),le("Q",U),he("Q",function(e,t){t[ge]=3*(O(e)-1)}),F("D",["DD",2],"Do","date"),P("date","D"),j("date",9),le("D",Q),le("DD",Q,G),le("Do",function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient}),he(["D","DD"],ye),he("Do",function(e,t){t[ye]=O(e.match(Q)[0])});var hn=ze("Date",!0);F("DDD",["DDDD",3],"DDDo","dayOfYear"),P("dayOfYear","DDD"),j("dayOfYear",4),le("DDD",te),le("DDDD",K),he(["DDD","DDDD"],function(e,t,n){n._dayOfYear=O(e)}),F("m",["mm",2],0,"minute"),P("minute","m"),j("minute",14),le("m",Q),le("mm",Q,G),he(["m","mm"],Me);var mn=ze("Minutes",!1);F("s",["ss",2],0,"second"),P("second","s"),j("second",15),le("s",Q),le("ss",Q,G),he(["s","ss"],Ee);var vn,bn=ze("Seconds",!1);for(F("S",0,0,function(){return~~(this.millisecond()/100)}),F(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),F(0,["SSS",3],0,"millisecond"),F(0,["SSSS",4],0,function(){return 10*this.millisecond()}),F(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),F(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),F(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),F(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),F(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),P("millisecond","ms"),j("millisecond",16),le("S",te,U),le("SS",te,G),le("SSS",te,K),vn="SSSS";vn.length<=9;vn+="S")le(vn,ae);function gn(e,t){t[Oe]=O(1e3*("0."+e))}for(vn="S";vn.length<=9;vn+="S")he(vn,gn);var yn=ze("Milliseconds",!1);F("z",0,0,"zoneAbbr"),F("zz",0,0,"zoneName");var _n=_.prototype;function Mn(e){return e}_n.add=Qt,_n.calendar=function(e,t){var n=e||Ct(),r=qt(n,this).startOf("day"),o=a.calendarFormat(this,r)||"sameElse",i=t&&(z(t[o])?t[o].call(this,n):t[o]);return this.format(i||this.localeData().calendar(o,this,Ct(n)))},_n.clone=function(){return new _(this)},_n.diff=function(e,t,n){var r,a,o;if(!this.isValid())return NaN;if(!(r=qt(e,this)).isValid())return NaN;switch(a=6e4*(r.utcOffset()-this.utcOffset()),t=x(t)){case"year":o=en(this,r)/12;break;case"month":o=en(this,r);break;case"quarter":o=en(this,r)/3;break;case"second":o=(this-r)/1e3;break;case"minute":o=(this-r)/6e4;break;case"hour":o=(this-r)/36e5;break;case"day":o=(this-r-a)/864e5;break;case"week":o=(this-r-a)/6048e5;break;default:o=this-r}return n?o:E(o)},_n.endOf=function(e){var t;if(void 0===(e=x(e))||"millisecond"===e||!this.isValid())return this;var n=this._isUTC?dn:ln;switch(e){case"year":t=n(this.year()+1,0,1)-1;break;case"quarter":t=n(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":t=n(this.year(),this.month()+1,1)-1;break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":t=n(this.year(),this.month(),this.date()+1)-1;break;case"hour":t=this._d.valueOf(),t+=sn-un(t+(this._isUTC?0:this.utcOffset()*on),sn)-1;break;case"minute":t=this._d.valueOf(),t+=on-un(t,on)-1;break;case"second":t=this._d.valueOf(),t+=an-un(t,an)-1}return this._d.setTime(t),a.updateOffset(this,!0),this},_n.format=function(e){e||(e=this.isUtc()?a.defaultFormatUtc:a.defaultFormat);var t=V(this,e);return this.localeData().postformat(t)},_n.from=function(e,t){return this.isValid()&&(M(e)&&e.isValid()||Ct(e).isValid())?Ut({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},_n.fromNow=function(e){return this.from(Ct(),e)},_n.to=function(e,t){return this.isValid()&&(M(e)&&e.isValid()||Ct(e).isValid())?Ut({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},_n.toNow=function(e){return this.to(Ct(),e)},_n.get=function(e){return z(this[e=x(e)])?this[e]():this},_n.invalidAt=function(){return h(this).overflow},_n.isAfter=function(e,t){var n=M(e)?e:Ct(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=x(t)||"millisecond")?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(t).valueOf())},_n.isBefore=function(e,t){var n=M(e)?e:Ct(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=x(t)||"millisecond")?this.valueOf()<n.valueOf():this.clone().endOf(t).valueOf()<n.valueOf())},_n.isBetween=function(e,t,n,r){var a=M(e)?e:Ct(e),o=M(t)?t:Ct(t);return!!(this.isValid()&&a.isValid()&&o.isValid())&&(("("===(r=r||"()")[0]?this.isAfter(a,n):!this.isBefore(a,n))&&(")"===r[1]?this.isBefore(o,n):!this.isAfter(o,n)))},_n.isSame=function(e,t){var n,r=M(e)?e:Ct(e);return!(!this.isValid()||!r.isValid())&&("millisecond"===(t=x(t)||"millisecond")?this.valueOf()===r.valueOf():(n=r.valueOf(),this.clone().startOf(t).valueOf()<=n&&n<=this.clone().endOf(t).valueOf()))},_n.isSameOrAfter=function(e,t){return this.isSame(e,t)||this.isAfter(e,t)},_n.isSameOrBefore=function(e,t){return this.isSame(e,t)||this.isBefore(e,t)},_n.isValid=function(){return m(this)},_n.lang=nn,_n.locale=tn,_n.localeData=rn,_n.max=Nt,_n.min=Dt,_n.parsingFlags=function(){return f({},h(this))},_n.set=function(e,t){if("object"==typeof e)for(var n=function(e){var t=[];for(var n in e)t.push({unit:n,priority:R[n]});return t.sort(function(e,t){return e.priority-t.priority}),t}(e=I(e)),r=0;r<n.length;r++)this[n[r].unit](e[n[r].unit]);else if(z(this[e=x(e)]))return this[e](t);return this},_n.startOf=function(e){var t;if(void 0===(e=x(e))||"millisecond"===e||!this.isValid())return this;var n=this._isUTC?dn:ln;switch(e){case"year":t=n(this.year(),0,1);break;case"quarter":t=n(this.year(),this.month()-this.month()%3,1);break;case"month":t=n(this.year(),this.month(),1);break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":t=n(this.year(),this.month(),this.date());break;case"hour":t=this._d.valueOf(),t-=un(t+(this._isUTC?0:this.utcOffset()*on),sn);break;case"minute":t=this._d.valueOf(),t-=un(t,on);break;case"second":t=this._d.valueOf(),t-=un(t,an)}return this._d.setTime(t),a.updateOffset(this,!0),this},_n.subtract=Zt,_n.toArray=function(){var e=this;return[e.year(),e.month(),e.date(),e.hour(),e.minute(),e.second(),e.millisecond()]},_n.toObject=function(){var e=this;return{years:e.year(),months:e.month(),date:e.date(),hours:e.hours(),minutes:e.minutes(),seconds:e.seconds(),milliseconds:e.milliseconds()}},_n.toDate=function(){return new Date(this.valueOf())},_n.toISOString=function(e){if(!this.isValid())return null;var t=!0!==e,n=t?this.clone().utc():this;return n.year()<0||n.year()>9999?V(n,t?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):z(Date.prototype.toISOString)?t?this.toDate().toISOString():new Date(this.valueOf()+60*this.utcOffset()*1e3).toISOString().replace("Z",V(n,"Z")):V(n,t?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")},_n.inspect=function(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e="moment",t="";this.isLocal()||(e=0===this.utcOffset()?"moment.utc":"moment.parseZone",t="Z");var n="["+e+'("]',r=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",a=t+'[")]';return this.format(n+r+"-MM-DD[T]HH:mm:ss.SSS"+a)},_n.toJSON=function(){return this.isValid()?this.toISOString():null},_n.toString=function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},_n.unix=function(){return Math.floor(this.valueOf()/1e3)},_n.valueOf=function(){return this._d.valueOf()-6e4*(this._offset||0)},_n.creationData=function(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}},_n.year=Te,_n.isLeapYear=function(){return Se(this.year())},_n.weekYear=function(e){return pn.call(this,e,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)},_n.isoWeekYear=function(e){return pn.call(this,e,this.isoWeek(),this.isoWeekday(),1,4)},_n.quarter=_n.quarters=function(e){return null==e?Math.ceil((this.month()+1)/3):this.month(3*(e-1)+this.month()%3)},_n.month=je,_n.daysInMonth=function(){return Ne(this.year(),this.month())},_n.week=_n.weeks=function(e){var t=this.localeData().week(this);return null==e?t:this.add(7*(e-t),"d")},_n.isoWeek=_n.isoWeeks=function(e){var t=Ve(this,1,4).week;return null==e?t:this.add(7*(e-t),"d")},_n.weeksInYear=function(){var e=this.localeData()._week;return Xe(this.year(),e.dow,e.doy)},_n.isoWeeksInYear=function(){return Xe(this.year(),1,4)},_n.date=hn,_n.day=_n.days=function(e){if(!this.isValid())return null!=e?this:NaN;var t=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=e?(e=function(e,t){return"string"!=typeof e?e:isNaN(e)?"number"==typeof(e=t.weekdaysParse(e))?e:null:parseInt(e,10)}(e,this.localeData()),this.add(e-t,"d")):t},_n.weekday=function(e){if(!this.isValid())return null!=e?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return null==e?t:this.add(e-t,"d")},_n.isoWeekday=function(e){if(!this.isValid())return null!=e?this:NaN;if(null!=e){var t=function(e,t){return"string"==typeof e?t.weekdaysParse(e)%7||7:isNaN(e)?null:e}(e,this.localeData());return this.day(this.day()%7?t:t-7)}return this.day()||7},_n.dayOfYear=function(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")},_n.hour=_n.hours=ot,_n.minute=_n.minutes=mn,_n.second=_n.seconds=bn,_n.millisecond=_n.milliseconds=yn,_n.utcOffset=function(e,t,n){var r,o=this._offset||0;if(!this.isValid())return null!=e?this:NaN;if(null!=e){if("string"==typeof e){if(null===(e=Yt(se,e)))return this}else Math.abs(e)<16&&!n&&(e*=60);return!this._isUTC&&t&&(r=Bt(this)),this._offset=e,this._isUTC=!0,null!=r&&this.add(r,"m"),o!==e&&(!t||this._changeInProgress?$t(this,Ut(e-o,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,a.updateOffset(this,!0),this._changeInProgress=null)),this}return this._isUTC?o:Bt(this)},_n.utc=function(e){return this.utcOffset(0,e)},_n.local=function(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(Bt(this),"m")),this},_n.parseZone=function(){if(null!=this._tzm)this.utcOffset(this._tzm,!1,!0);else if("string"==typeof this._i){var e=Yt(ie,this._i);null!=e?this.utcOffset(e):this.utcOffset(0,!0)}return this},_n.hasAlignedHourOffset=function(e){return!!this.isValid()&&(e=e?Ct(e).utcOffset():0,(this.utcOffset()-e)%60==0)},_n.isDST=function(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},_n.isLocal=function(){return!!this.isValid()&&!this._isUTC},_n.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},_n.isUtc=Ft,_n.isUTC=Ft,_n.zoneAbbr=function(){return this._isUTC?"UTC":""},_n.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},_n.dates=L("dates accessor is deprecated. Use date instead.",hn),_n.months=L("months accessor is deprecated. Use month instead",je),_n.years=L("years accessor is deprecated. Use year instead",Te),_n.zone=L("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",function(e,t){return null!=e?("string"!=typeof e&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()}),_n.isDSTShifted=L("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",function(){if(!s(this._isDSTShifted))return this._isDSTShifted;var e={};if(g(e,this),(e=Tt(e))._a){var t=e._isUTC?p(e._a):Ct(e._a);this._isDSTShifted=this.isValid()&&w(e._a,t.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted});var En=D.prototype;function On(e,t,n,r){var a=pt(),o=p().set(r,t);return a[n](o,e)}function wn(e,t,n){if(c(e)&&(t=e,e=void 0),e=e||"",null!=t)return On(e,t,n,"month");var r,a=[];for(r=0;r<12;r++)a[r]=On(e,r,n,"month");return a}function kn(e,t,n,r){"boolean"==typeof e?(c(t)&&(n=t,t=void 0),t=t||""):(n=t=e,e=!1,c(t)&&(n=t,t=void 0),t=t||"");var a,o=pt(),i=e?o._week.dow:0;if(null!=n)return On(t,(n+i)%7,r,"day");var s=[];for(a=0;a<7;a++)s[a]=On(t,(a+i)%7,r,"day");return s}En.calendar=function(e,t,n){var r=this._calendar[e]||this._calendar.sameElse;return z(r)?r.call(t,n):r},En.longDateFormat=function(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.replace(/MMMM|MM|DD|dddd/g,function(e){return e.slice(1)}),this._longDateFormat[e])},En.invalidDate=function(){return this._invalidDate},En.ordinal=function(e){return this._ordinal.replace("%d",e)},En.preparse=Mn,En.postformat=Mn,En.relativeTime=function(e,t,n,r){var a=this._relativeTime[n];return z(a)?a(e,t,n,r):a.replace(/%d/i,e)},En.pastFuture=function(e,t){var n=this._relativeTime[e>0?"future":"past"];return z(n)?n(t):n.replace(/%s/i,t)},En.set=function(e){var t,n;for(n in e)z(t=e[n])?this[n]=t:this["_"+n]=t;this._config=e,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)},En.months=function(e,t){return e?o(this._months)?this._months[e.month()]:this._months[(this._months.isFormat||Pe).test(t)?"format":"standalone"][e.month()]:o(this._months)?this._months:this._months.standalone},En.monthsShort=function(e,t){return e?o(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[Pe.test(t)?"format":"standalone"][e.month()]:o(this._monthsShort)?this._monthsShort:this._monthsShort.standalone},En.monthsParse=function(e,t,n){var r,a,o;if(this._monthsParseExact)return function(e,t,n){var r,a,o,i=e.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],r=0;r<12;++r)o=p([2e3,r]),this._shortMonthsParse[r]=this.monthsShort(o,"").toLocaleLowerCase(),this._longMonthsParse[r]=this.months(o,"").toLocaleLowerCase();return n?"MMM"===t?-1!==(a=Ae.call(this._shortMonthsParse,i))?a:null:-1!==(a=Ae.call(this._longMonthsParse,i))?a:null:"MMM"===t?-1!==(a=Ae.call(this._shortMonthsParse,i))?a:-1!==(a=Ae.call(this._longMonthsParse,i))?a:null:-1!==(a=Ae.call(this._longMonthsParse,i))?a:-1!==(a=Ae.call(this._shortMonthsParse,i))?a:null}.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),r=0;r<12;r++){if(a=p([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(a,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(a,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(o="^"+this.months(a,"")+"|^"+this.monthsShort(a,""),this._monthsParse[r]=new RegExp(o.replace(".",""),"i")),n&&"MMMM"===t&&this._longMonthsParse[r].test(e))return r;if(n&&"MMM"===t&&this._shortMonthsParse[r].test(e))return r;if(!n&&this._monthsParse[r].test(e))return r}},En.monthsRegex=function(e){return this._monthsParseExact?(d(this,"_monthsRegex")||Ye.call(this),e?this._monthsStrictRegex:this._monthsRegex):(d(this,"_monthsRegex")||(this._monthsRegex=We),this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex)},En.monthsShortRegex=function(e){return this._monthsParseExact?(d(this,"_monthsRegex")||Ye.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):(d(this,"_monthsShortRegex")||(this._monthsShortRegex=He),this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex)},En.week=function(e){return Ve(e,this._week.dow,this._week.doy).week},En.firstDayOfYear=function(){return this._week.doy},En.firstDayOfWeek=function(){return this._week.dow},En.weekdays=function(e,t){var n=o(this._weekdays)?this._weekdays:this._weekdays[e&&!0!==e&&this._weekdays.isFormat.test(t)?"format":"standalone"];return!0===e?Ue(n,this._week.dow):e?n[e.day()]:n},En.weekdaysMin=function(e){return!0===e?Ue(this._weekdaysMin,this._week.dow):e?this._weekdaysMin[e.day()]:this._weekdaysMin},En.weekdaysShort=function(e){return!0===e?Ue(this._weekdaysShort,this._week.dow):e?this._weekdaysShort[e.day()]:this._weekdaysShort},En.weekdaysParse=function(e,t,n){var r,a,o;if(this._weekdaysParseExact)return function(e,t,n){var r,a,o,i=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],r=0;r<7;++r)o=p([2e3,1]).day(r),this._minWeekdaysParse[r]=this.weekdaysMin(o,"").toLocaleLowerCase(),this._shortWeekdaysParse[r]=this.weekdaysShort(o,"").toLocaleLowerCase(),this._weekdaysParse[r]=this.weekdays(o,"").toLocaleLowerCase();return n?"dddd"===t?-1!==(a=Ae.call(this._weekdaysParse,i))?a:null:"ddd"===t?-1!==(a=Ae.call(this._shortWeekdaysParse,i))?a:null:-1!==(a=Ae.call(this._minWeekdaysParse,i))?a:null:"dddd"===t?-1!==(a=Ae.call(this._weekdaysParse,i))?a:-1!==(a=Ae.call(this._shortWeekdaysParse,i))?a:-1!==(a=Ae.call(this._minWeekdaysParse,i))?a:null:"ddd"===t?-1!==(a=Ae.call(this._shortWeekdaysParse,i))?a:-1!==(a=Ae.call(this._weekdaysParse,i))?a:-1!==(a=Ae.call(this._minWeekdaysParse,i))?a:null:-1!==(a=Ae.call(this._minWeekdaysParse,i))?a:-1!==(a=Ae.call(this._weekdaysParse,i))?a:-1!==(a=Ae.call(this._shortWeekdaysParse,i))?a:null}.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),r=0;r<7;r++){if(a=p([2e3,1]).day(r),n&&!this._fullWeekdaysParse[r]&&(this._fullWeekdaysParse[r]=new RegExp("^"+this.weekdays(a,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[r]=new RegExp("^"+this.weekdaysShort(a,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[r]=new RegExp("^"+this.weekdaysMin(a,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[r]||(o="^"+this.weekdays(a,"")+"|^"+this.weekdaysShort(a,"")+"|^"+this.weekdaysMin(a,""),this._weekdaysParse[r]=new RegExp(o.replace(".",""),"i")),n&&"dddd"===t&&this._fullWeekdaysParse[r].test(e))return r;if(n&&"ddd"===t&&this._shortWeekdaysParse[r].test(e))return r;if(n&&"dd"===t&&this._minWeekdaysParse[r].test(e))return r;if(!n&&this._weekdaysParse[r].test(e))return r}},En.weekdaysRegex=function(e){return this._weekdaysParseExact?(d(this,"_weekdaysRegex")||et.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):(d(this,"_weekdaysRegex")||(this._weekdaysRegex=$e),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)},En.weekdaysShortRegex=function(e){return this._weekdaysParseExact?(d(this,"_weekdaysRegex")||et.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(d(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=Qe),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)},En.weekdaysMinRegex=function(e){return this._weekdaysParseExact?(d(this,"_weekdaysRegex")||et.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(d(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=Ze),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)},En.isPM=function(e){return"p"===(e+"").toLowerCase().charAt(0)},En.meridiem=function(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"},dt("en",{dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10,n=1===O(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+n}}),a.lang=L("moment.lang is deprecated. Use moment.locale instead.",dt),a.langData=L("moment.langData is deprecated. Use moment.localeData instead.",pt);var Ln=Math.abs;function Sn(e,t,n,r){var a=Ut(t,n);return e._milliseconds+=r*a._milliseconds,e._days+=r*a._days,e._months+=r*a._months,e._bubble()}function An(e){return e<0?Math.floor(e):Math.ceil(e)}function Tn(e){return 4800*e/146097}function zn(e){return 146097*e/4800}function Cn(e){return function(){return this.as(e)}}var Dn=Cn("ms"),Nn=Cn("s"),Pn=Cn("m"),xn=Cn("h"),In=Cn("d"),Rn=Cn("w"),jn=Cn("M"),Hn=Cn("Q"),Wn=Cn("y");function Yn(e){return function(){return this.isValid()?this._data[e]:NaN}}var qn=Yn("milliseconds"),Bn=Yn("seconds"),Fn=Yn("minutes"),Vn=Yn("hours"),Xn=Yn("days"),Un=Yn("months"),Gn=Yn("years"),Kn=Math.round,Jn={ss:44,s:45,m:45,h:22,d:26,M:11},$n=Math.abs;function Qn(e){return(e>0)-(e<0)||+e}function Zn(){if(!this.isValid())return this.localeData().invalidDate();var e,t,n=$n(this._milliseconds)/1e3,r=$n(this._days),a=$n(this._months);e=E(n/60),t=E(e/60),n%=60,e%=60;var o=E(a/12),i=a%=12,s=r,c=t,u=e,l=n?n.toFixed(3).replace(/\.?0+$/,""):"",d=this.asSeconds();if(!d)return"P0D";var f=d<0?"-":"",p=Qn(this._months)!==Qn(d)?"-":"",h=Qn(this._days)!==Qn(d)?"-":"",m=Qn(this._milliseconds)!==Qn(d)?"-":"";return f+"P"+(o?p+o+"Y":"")+(i?p+i+"M":"")+(s?h+s+"D":"")+(c||u||l?"T":"")+(c?m+c+"H":"")+(u?m+u+"M":"")+(l?m+l+"S":"")}var er=It.prototype;return er.isValid=function(){return this._isValid},er.abs=function(){var e=this._data;return this._milliseconds=Ln(this._milliseconds),this._days=Ln(this._days),this._months=Ln(this._months),e.milliseconds=Ln(e.milliseconds),e.seconds=Ln(e.seconds),e.minutes=Ln(e.minutes),e.hours=Ln(e.hours),e.months=Ln(e.months),e.years=Ln(e.years),this},er.add=function(e,t){return Sn(this,e,t,1)},er.subtract=function(e,t){return Sn(this,e,t,-1)},er.as=function(e){if(!this.isValid())return NaN;var t,n,r=this._milliseconds;if("month"===(e=x(e))||"quarter"===e||"year"===e)switch(t=this._days+r/864e5,n=this._months+Tn(t),e){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(t=this._days+Math.round(zn(this._months)),e){case"week":return t/7+r/6048e5;case"day":return t+r/864e5;case"hour":return 24*t+r/36e5;case"minute":return 1440*t+r/6e4;case"second":return 86400*t+r/1e3;case"millisecond":return Math.floor(864e5*t)+r;default:throw new Error("Unknown unit "+e)}},er.asMilliseconds=Dn,er.asSeconds=Nn,er.asMinutes=Pn,er.asHours=xn,er.asDays=In,er.asWeeks=Rn,er.asMonths=jn,er.asQuarters=Hn,er.asYears=Wn,er.valueOf=function(){return this.isValid()?this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*O(this._months/12):NaN},er._bubble=function(){var e,t,n,r,a,o=this._milliseconds,i=this._days,s=this._months,c=this._data;return o>=0&&i>=0&&s>=0||o<=0&&i<=0&&s<=0||(o+=864e5*An(zn(s)+i),i=0,s=0),c.milliseconds=o%1e3,e=E(o/1e3),c.seconds=e%60,t=E(e/60),c.minutes=t%60,n=E(t/60),c.hours=n%24,i+=E(n/24),a=E(Tn(i)),s+=a,i-=An(zn(a)),r=E(s/12),s%=12,c.days=i,c.months=s,c.years=r,this},er.clone=function(){return Ut(this)},er.get=function(e){return e=x(e),this.isValid()?this[e+"s"]():NaN},er.milliseconds=qn,er.seconds=Bn,er.minutes=Fn,er.hours=Vn,er.days=Xn,er.weeks=function(){return E(this.days()/7)},er.months=Un,er.years=Gn,er.humanize=function(e){if(!this.isValid())return this.localeData().invalidDate();var t=this.localeData(),n=function(e,t,n){var r=Ut(e).abs(),a=Kn(r.as("s")),o=Kn(r.as("m")),i=Kn(r.as("h")),s=Kn(r.as("d")),c=Kn(r.as("M")),u=Kn(r.as("y")),l=a<=Jn.ss&&["s",a]||a<Jn.s&&["ss",a]||o<=1&&["m"]||o<Jn.m&&["mm",o]||i<=1&&["h"]||i<Jn.h&&["hh",i]||s<=1&&["d"]||s<Jn.d&&["dd",s]||c<=1&&["M"]||c<Jn.M&&["MM",c]||u<=1&&["y"]||["yy",u];return l[2]=t,l[3]=+e>0,l[4]=n,function(e,t,n,r,a){return a.relativeTime(t||1,!!n,e,r)}.apply(null,l)}(this,!e,t);return e&&(n=t.pastFuture(+this,n)),t.postformat(n)},er.toISOString=Zn,er.toString=Zn,er.toJSON=Zn,er.locale=tn,er.localeData=rn,er.toIsoString=L("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Zn),er.lang=nn,F("X",0,0,"unix"),F("x",0,0,"valueOf"),le("x",oe),le("X",/[+-]?\d+(\.\d{1,3})?/),he("X",function(e,t,n){n._d=new Date(1e3*parseFloat(e,10))}),he("x",function(e,t,n){n._d=new Date(O(e))}),a.version="2.24.0",t=Ct,a.fn=_n,a.min=function(){return Pt("isBefore",[].slice.call(arguments,0))},a.max=function(){return Pt("isAfter",[].slice.call(arguments,0))},a.now=function(){return Date.now?Date.now():+new Date},a.utc=p,a.unix=function(e){return Ct(1e3*e)},a.months=function(e,t){return wn(e,t,"months")},a.isDate=u,a.locale=dt,a.invalid=v,a.duration=Ut,a.isMoment=M,a.weekdays=function(e,t,n){return kn(e,t,n,"weekdays")},a.parseZone=function(){return Ct.apply(null,arguments).parseZone()},a.localeData=pt,a.isDuration=Rt,a.monthsShort=function(e,t){return wn(e,t,"monthsShort")},a.weekdaysMin=function(e,t,n){return kn(e,t,n,"weekdaysMin")},a.defineLocale=ft,a.updateLocale=function(e,t){if(null!=t){var n,r,a=it;null!=(r=lt(e))&&(a=r._config),t=C(a,t),(n=new D(t)).parentLocale=st[e],st[e]=n,dt(e)}else null!=st[e]&&(null!=st[e].parentLocale?st[e]=st[e].parentLocale:null!=st[e]&&delete st[e]);return st[e]},a.locales=function(){return S(st)},a.weekdaysShort=function(e,t,n){return kn(e,t,n,"weekdaysShort")},a.normalizeUnits=x,a.relativeTimeRounding=function(e){return void 0===e?Kn:"function"==typeof e&&(Kn=e,!0)},a.relativeTimeThreshold=function(e,t){return void 0!==Jn[e]&&(void 0===t?Jn[e]:(Jn[e]=t,"s"===e&&(Jn.ss=t-1),!0))},a.calendarFormat=function(e,t){var n=e.diff(t,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"},a.prototype=_n,a.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},a}()}).call(this,n(303)(e))},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(t)}e.exports=n},function(e,t,n){var r=n(658),a=n(6);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?a(e):t}},function(e,t,n){var r=n(304);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)}},function(e,t){function n(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e.exports=function(e,t,r){return t&&n(e.prototype,t),r&&n(e,r),e}},function(e,t,n){var r=n(19),a=n(63),o=n(41),i=n(37),s=n(50),c=function(e,t,n){var u,l,d,f,p=e&c.F,h=e&c.G,m=e&c.S,v=e&c.P,b=e&c.B,g=h?r:m?r[t]||(r[t]={}):(r[t]||{}).prototype,y=h?a:a[t]||(a[t]={}),_=y.prototype||(y.prototype={});for(u in h&&(n=t),n)d=((l=!p&&g&&void 0!==g[u])?g:n)[u],f=b&&l?s(d,r):v&&"function"==typeof d?s(Function.call,d):d,g&&i(g,u,d,e&c.U),y[u]!=d&&o(y,u,f),v&&_[u]!=d&&(_[u]=d)};r.core=a,c.F=1,c.G=2,c.S=4,c.P=8,c.B=16,c.W=32,c.U=64,c.R=128,e.exports=c},function(e,t,n){var r=n(456),a=n(332),o=n(457);e.exports=function(e){return r(e)||a(e)||o()}},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},n.apply(this,arguments)}e.exports=n},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},a=function(){function e(e,t){for(var n,r=0;r<t.length;r++)(n=t[r]).enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=n(0),i=c(o),s=c(n(2));function c(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var u=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,o.PureComponent),a(t,[{key:"needsOffset",value:function(e,t){return!!(0<=["gridicons-add-outline","gridicons-add","gridicons-align-image-center","gridicons-align-image-left","gridicons-align-image-none","gridicons-align-image-right","gridicons-attachment","gridicons-bold","gridicons-bookmark-outline","gridicons-bookmark","gridicons-calendar","gridicons-cart","gridicons-create","gridicons-custom-post-type","gridicons-external","gridicons-folder","gridicons-heading","gridicons-help-outline","gridicons-help","gridicons-history","gridicons-info-outline","gridicons-info","gridicons-italic","gridicons-layout-blocks","gridicons-link-break","gridicons-link","gridicons-list-checkmark","gridicons-list-ordered","gridicons-list-unordered","gridicons-menus","gridicons-minus","gridicons-my-sites","gridicons-notice-outline","gridicons-notice","gridicons-plus-small","gridicons-plus","gridicons-popout","gridicons-posts","gridicons-scheduled","gridicons-share-ios","gridicons-star-outline","gridicons-star","gridicons-stats","gridicons-status","gridicons-thumbs-up","gridicons-textcolor","gridicons-time","gridicons-trophy","gridicons-user-circle","gridicons-reader-follow","gridicons-reader-following"].indexOf(e))&&0==t%18}},{key:"needsOffsetX",value:function(e,t){return!!(0<=["gridicons-arrow-down","gridicons-arrow-up","gridicons-comment","gridicons-clear-formatting","gridicons-flag","gridicons-menu","gridicons-reader","gridicons-strikethrough"].indexOf(e))&&0==t%18}},{key:"needsOffsetY",value:function(e,t){return!!(0<=["gridicons-align-center","gridicons-align-justify","gridicons-align-left","gridicons-align-right","gridicons-arrow-left","gridicons-arrow-right","gridicons-house","gridicons-indent-left","gridicons-indent-right","gridicons-minus-small","gridicons-print","gridicons-sign-out","gridicons-stats-alt","gridicons-trash","gridicons-underline","gridicons-video-camera"].indexOf(e))&&0==t%18}},{key:"render",value:function(){var e=this.props,t=e.size,n=e.onClick,a=e.icon,o=e.className,s=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"]),c="gridicons-"+a,u=void 0,l=["gridicon",c,o,!!this.needsOffset(c,t)&&"needs-offset",!!this.needsOffsetX(c,t)&&"needs-offset-x",!!this.needsOffsetY(c,t)&&"needs-offset-y"].filter(Boolean).join(" ");switch(c){default:u=i.default.createElement("svg",r({height:t,width:t},s));break;case"gridicons-add-image":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M23 4v2h-3v3h-2V6h-3V4h3V1h2v3h3zm-8.5 7c.828 0 1.5-.672 1.5-1.5S15.328 8 14.5 8 13 8.672 13 9.5s.672 1.5 1.5 1.5zm3.5 3.234l-.513-.57c-.794-.885-2.18-.885-2.976 0l-.655.73L9 9l-3 3.333V6h7V4H6c-1.105 0-2 .895-2 2v12c0 1.105.895 2 2 2h12c1.105 0 2-.895 2-2v-7h-2v3.234z"})));break;case"gridicons-add-outline":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 4c4.41 0 8 3.59 8 8s-3.59 8-8 8-8-3.59-8-8 3.59-8 8-8m0-2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm5 9h-4V7h-2v4H7v2h4v4h2v-4h4v-2z"})));break;case"gridicons-add":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm5 11h-4v4h-2v-4H7v-2h4V7h2v4h4v2z"})));break;case"gridicons-align-center":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M4 19h16v-2H4v2zm13-6H7v2h10v-2zM4 9v2h16V9H4zm13-4H7v2h10V5z"})));break;case"gridicons-align-image-center":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M3 5h18v2H3V5zm0 14h18v-2H3v2zm5-4h8V9H8v6z"})));break;case"gridicons-align-image-left":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M3 5h18v2H3V5zm0 14h18v-2H3v2zm0-4h8V9H3v6zm10 0h8v-2h-8v2zm0-4h8V9h-8v2z"})));break;case"gridicons-align-image-none":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M21 7H3V5h18v2zm0 10H3v2h18v-2zM11 9H3v6h8V9z"})));break;case"gridicons-align-image-right":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M21 7H3V5h18v2zm0 10H3v2h18v-2zm0-8h-8v6h8V9zm-10 4H3v2h8v-2zm0-4H3v2h8V9z"})));break;case"gridicons-align-justify":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M4 19h16v-2H4v2zm16-6H4v2h16v-2zM4 9v2h16V9H4zm16-4H4v2h16V5z"})));break;case"gridicons-align-left":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M4 19h16v-2H4v2zm10-6H4v2h10v-2zM4 9v2h16V9H4zm10-4H4v2h10V5z"})));break;case"gridicons-align-right":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 17H4v2h16v-2zm-10-2h10v-2H10v2zM4 9v2h16V9H4zm6-2h10V5H10v2z"})));break;case"gridicons-arrow-down":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M11 4v12.17l-5.59-5.59L4 12l8 8 8-8-1.41-1.41L13 16.17V4h-2z"})));break;case"gridicons-arrow-left":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z"})));break;case"gridicons-arrow-right":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 4l-1.41 1.41L16.17 11H4v2h12.17l-5.58 5.59L12 20l8-8-8-8z"})));break;case"gridicons-arrow-up":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M13 20V7.83l5.59 5.59L20 12l-8-8-8 8 1.41 1.41L11 7.83V20h2z"})));break;case"gridicons-aside":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M14 20l6-6V6c0-1.105-.895-2-2-2H6c-1.105 0-2 .895-2 2v12c0 1.105.895 2 2 2h8zM6 6h12v6h-4c-1.105 0-2 .895-2 2v4H6V6zm10 4H8V8h8v2z"})));break;case"gridicons-attachment":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M14 1c-2.762 0-5 2.238-5 5v10c0 1.657 1.343 3 3 3s2.99-1.343 2.99-3V6H13v10c0 .553-.447 1-1 1-.553 0-1-.447-1-1V6c0-1.657 1.343-3 3-3s3 1.343 3 3v10.125C17 18.887 14.762 21 12 21s-5-2.238-5-5v-5H5v5c0 3.866 3.134 7 7 7s6.99-3.134 6.99-7V6c0-2.762-2.228-5-4.99-5z"})));break;case"gridicons-audio":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M8 4v10.184C7.686 14.072 7.353 14 7 14c-1.657 0-3 1.343-3 3s1.343 3 3 3 3-1.343 3-3V7h7v4.184c-.314-.112-.647-.184-1-.184-1.657 0-3 1.343-3 3s1.343 3 3 3 3-1.343 3-3V4H8z"})));break;case"gridicons-bell":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M6.14 14.97l2.828 2.827c-.362.362-.862.586-1.414.586-1.105 0-2-.895-2-2 0-.552.224-1.052.586-1.414zm8.867 5.324L14.3 21 3 9.7l.706-.707 1.102.157c.754.108 1.69-.122 2.077-.51l3.885-3.884c2.34-2.34 6.135-2.34 8.475 0s2.34 6.135 0 8.475l-3.885 3.886c-.388.388-.618 1.323-.51 2.077l.157 1.1z"})));break;case"gridicons-block":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zM4 12c0-4.418 3.582-8 8-8 1.848 0 3.545.633 4.9 1.686L5.686 16.9C4.633 15.545 4 13.848 4 12zm8 8c-1.848 0-3.546-.633-4.9-1.686L18.314 7.1C19.367 8.455 20 10.152 20 12c0 4.418-3.582 8-8 8z"})));break;case"gridicons-bold":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M7 5.01h4.547c2.126 0 3.67.302 4.632.906.96.605 1.44 1.567 1.44 2.887 0 .896-.21 1.63-.63 2.205-.42.574-.98.92-1.678 1.036v.103c.95.212 1.637.608 2.057 1.19.42.58.63 1.35.63 2.315 0 1.367-.494 2.434-1.482 3.2-.99.765-2.332 1.148-4.027 1.148H7V5.01zm3 5.936h2.027c.862 0 1.486-.133 1.872-.4.386-.267.578-.708.578-1.323 0-.574-.21-.986-.63-1.236-.42-.25-1.087-.374-1.996-.374H10v3.333zm0 2.523v3.905h2.253c.876 0 1.52-.167 1.94-.502.416-.335.625-.848.625-1.54 0-1.243-.89-1.864-2.668-1.864H10z"})));break;case"gridicons-book":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M4 3h2v18H4zM18 3H7v18h11c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 6h-6V8h6v1zm0-2h-6V6h6v1z"})));break;case"gridicons-bookmark-outline":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M17 5v12.554l-5-2.857-5 2.857V5h10m0-2H7c-1.105 0-2 .896-2 2v16l7-4 7 4V5c0-1.104-.896-2-2-2z"})));break;case"gridicons-bookmark":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M17 3H7c-1.105 0-2 .896-2 2v16l7-4 7 4V5c0-1.104-.896-2-2-2z"})));break;case"gridicons-briefcase":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M14 15h-4v-2H2v6c0 1.105.895 2 2 2h16c1.105 0 2-.895 2-2v-6h-8v2zm6-9h-2V4c0-1.105-.895-2-2-2H8c-1.105 0-2 .895-2 2v2H4c-1.105 0-2 .895-2 2v4h20V8c0-1.105-.895-2-2-2zm-4 0H8V4h8v2z"})));break;case"gridicons-bug":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 14h4v-2h-4v-2h1a2 2 0 0 0 2-2V6h-2v2H5V6H3v2a2 2 0 0 0 2 2h1v2H2v2h4v1a6 6 0 0 0 .09 1H5a2 2 0 0 0-2 2v2h2v-2h1.81A6 6 0 0 0 11 20.91V10h2v10.91A6 6 0 0 0 17.19 18H19v2h2v-2a2 2 0 0 0-2-2h-1.09a6 6 0 0 0 .09-1zM12 2a4 4 0 0 0-4 4h8a4 4 0 0 0-4-4z"})));break;case"gridicons-calendar":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M19 4h-1V2h-2v2H8V2H6v2H5c-1.105 0-2 .896-2 2v13c0 1.104.895 2 2 2h14c1.104 0 2-.896 2-2V6c0-1.104-.896-2-2-2zm0 15H5V8h14v11z"})));break;case"gridicons-camera":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M17 12c0 1.7-1.3 3-3 3s-3-1.3-3-3 1.3-3 3-3 3 1.3 3 3zm5-5v11c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V7c0-1.1.9-2 2-2V4h4v1h2l1-2h6l1 2h2c1.1 0 2 .9 2 2zM7.5 9c0-.8-.7-1.5-1.5-1.5S4.5 8.2 4.5 9s.7 1.5 1.5 1.5S7.5 9.8 7.5 9zM19 12c0-2.8-2.2-5-5-5s-5 2.2-5 5 2.2 5 5 5 5-2.2 5-5z"})));break;case"gridicons-caption":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 15l2-2v5c0 1.105-.895 2-2 2H4c-1.105 0-2-.895-2-2V6c0-1.105.895-2 2-2h13l-2 2H4v12h16v-3zm2.44-8.56l-.88-.88c-.586-.585-1.534-.585-2.12 0L12 13v2H6v2h9v-1l7.44-7.44c.585-.586.585-1.534 0-2.12z"})));break;case"gridicons-cart":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M9 20c0 1.1-.9 2-2 2s-1.99-.9-1.99-2S5.9 18 7 18s2 .9 2 2zm8-2c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2zm.396-5c.937 0 1.75-.65 1.952-1.566L21 5H7V4c0-1.105-.895-2-2-2H3v2h2v11c0 1.105.895 2 2 2h12c0-1.105-.895-2-2-2H7v-2h10.396z"})));break;case"gridicons-chat":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M3 12c-1.1 0-2-.9-2-2V5c0-1.1.9-2 2-2h8c1.1 0 2 .9 2 2v5c0 1.1-.9 2-2 2H9v3l-3-3H3zM21 18c1.1 0 2-.9 2-2v-5c0-1.1-.9-2-2-2h-6v1c0 2.2-1.8 4-4 4v2c0 1.1.9 2 2 2h2v3l3-3h3z"})));break;case"gridicons-checkmark-circle":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M11 17.768l-4.884-4.884 1.768-1.768L11 14.232l8.658-8.658C17.823 3.39 15.075 2 12 2 6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10c0-1.528-.353-2.97-.966-4.266L11 17.768z"})));break;case"gridicons-checkmark":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M9 19.414l-6.707-6.707 1.414-1.414L9 16.586 20.293 5.293l1.414 1.414"})));break;case"gridicons-chevron-down":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 9l-8 8-8-8 1.414-1.414L12 14.172l6.586-6.586"})));break;case"gridicons-chevron-left":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M14 20l-8-8 8-8 1.414 1.414L8.828 12l6.586 6.586"})));break;case"gridicons-chevron-right":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M10 20l8-8-8-8-1.414 1.414L15.172 12l-6.586 6.586"})));break;case"gridicons-chevron-up":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M4 15l8-8 8 8-1.414 1.414L12 9.828l-6.586 6.586"})));break;case"gridicons-clear-formatting":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M10.837 10.163l-4.6 4.6L10 4h4l.777 2.223-2.144 2.144-.627-2.092-1.17 3.888zm5.495.506L19.244 19H15.82l-1.05-3.5H11.5L5 22l-1.5-1.5 17-17L22 5l-5.668 5.67zm-2.31 2.31l-.032.03.032-.01v-.02z"})));break;case"gridicons-clipboard":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M16 18H8v-2h8v2zm0-6H8v2h8v-2zm2-9h-2v2h2v15H6V5h2V3H6c-1.105 0-2 .895-2 2v15c0 1.105.895 2 2 2h12c1.105 0 2-.895 2-2V5c0-1.105-.895-2-2-2zm-4 2V4c0-1.105-.895-2-2-2s-2 .895-2 2v1c-1.105 0-2 .895-2 2v1h8V7c0-1.105-.895-2-2-2z"})));break;case"gridicons-cloud-download":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 9c-.01 0-.017.002-.025.003C17.72 5.646 14.922 3 11.5 3 7.91 3 5 5.91 5 9.5c0 .524.07 1.03.186 1.52C5.123 11.015 5.064 11 5 11c-2.21 0-4 1.79-4 4 0 1.202.54 2.267 1.38 3h18.593C22.196 17.09 23 15.643 23 14c0-2.76-2.24-5-5-5zm-6 7l-4-5h3V8h2v3h3l-4 5z"})));break;case"gridicons-cloud-outline":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M11.5 5c2.336 0 4.304 1.825 4.48 4.154l.142 1.86 1.867-.012h.092C19.698 11.043 21 12.37 21 14c0 .748-.28 1.452-.783 2H3.28c-.156-.256-.28-.59-.28-1 0-1.074.85-1.953 1.915-1.998.06.007.118.012.178.015l2.66.124-.622-2.587C7.044 10.186 7 9.843 7 9.5 7 7.02 9.02 5 11.5 5m0-2C7.91 3 5 5.91 5 9.5c0 .524.07 1.03.186 1.52C5.123 11.015 5.064 11 5 11c-2.21 0-4 1.79-4 4 0 1.202.54 2.267 1.38 3h18.593C22.196 17.09 23 15.643 23 14c0-2.76-2.24-5-5-5l-.025.002C17.72 5.646 14.922 3 11.5 3z"})));break;case"gridicons-cloud-upload":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 9c-.01 0-.017.002-.025.003C17.72 5.646 14.922 3 11.5 3 7.91 3 5 5.91 5 9.5c0 .524.07 1.03.186 1.52C5.123 11.015 5.064 11 5 11c-2.21 0-4 1.79-4 4 0 1.202.54 2.267 1.38 3h18.593C22.196 17.09 23 15.643 23 14c0-2.76-2.24-5-5-5zm-5 4v3h-2v-3H8l4-5 4 5h-3z"})));break;case"gridicons-cloud":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 9c-.01 0-.017.002-.025.003C17.72 5.646 14.922 3 11.5 3 7.91 3 5 5.91 5 9.5c0 .524.07 1.03.186 1.52C5.123 11.015 5.064 11 5 11c-2.21 0-4 1.79-4 4 0 1.202.54 2.267 1.38 3h18.593C22.196 17.09 23 15.643 23 14c0-2.76-2.24-5-5-5z"})));break;case"gridicons-code":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M23 12l-5.45 6.5L16 17.21 20.39 12 16 6.79l1.55-1.29zM8 6.79L6.45 5.5 1 12l5.45 6.5L8 17.21 3.61 12zm.45 14.61l1.93.52L15.55 2.6l-1.93-.52z"})));break;case"gridicons-cog":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 12c0-.568-.06-1.122-.174-1.656l1.834-1.612-2-3.464-2.322.786c-.82-.736-1.787-1.308-2.86-1.657L14 2h-4l-.48 2.396c-1.07.35-2.04.92-2.858 1.657L4.34 5.268l-2 3.464 1.834 1.612C4.06 10.878 4 11.432 4 12s.06 1.122.174 1.656L2.34 15.268l2 3.464 2.322-.786c.82.736 1.787 1.308 2.86 1.657L10 22h4l.48-2.396c1.07-.35 2.038-.92 2.858-1.657l2.322.786 2-3.464-1.834-1.613c.113-.535.174-1.09.174-1.657zm-8 4c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4z"})));break;case"gridicons-comment":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 16l-5 5v-5H5c-1.1 0-2-.9-2-2V5c0-1.1.9-2 2-2h14c1.1 0 2 .9 2 2v9c0 1.1-.9 2-2 2h-7z"})));break;case"gridicons-computer":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 2H4c-1.104 0-2 .896-2 2v12c0 1.104.896 2 2 2h6v2H7v2h10v-2h-3v-2h6c1.104 0 2-.896 2-2V4c0-1.104-.896-2-2-2zm0 14H4V4h16v12z"})));break;case"gridicons-coupon":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M13 16v2h-2v-2h2zm3-3h2v-2h-2v2zm2 8h-2v2h2v-2zm3-5v2h2v-2h-2zm-1-3c.552 0 1 .448 1 1h2c0-1.657-1.343-3-3-3v2zm1 7c0 .552-.448 1-1 1v2c1.657 0 3-1.343 3-3h-2zm-7 1c-.552 0-1-.448-1-1h-2c0 1.657 1.343 3 3 3v-2zm3.21-5.21c-.78.78-2.047.782-2.828.002l-.002-.002L10 11.41l-1.43 1.44c.28.506.427 1.073.43 1.65C9 16.433 7.433 18 5.5 18S2 16.433 2 14.5 3.567 11 5.5 11c.577.003 1.144.15 1.65.43L8.59 10 7.15 8.57c-.506.28-1.073.427-1.65.43C3.567 9 2 7.433 2 5.5S3.567 2 5.5 2 9 3.567 9 5.5c-.003.577-.15 1.144-.43 1.65L10 8.59l3.88-3.88c.78-.78 2.047-.782 2.828-.002l.002.002-5.3 5.29 5.8 5.79zM5.5 7C6.328 7 7 6.328 7 5.5S6.328 4 5.5 4 4 4.672 4 5.5 4.672 7 5.5 7zM7 14.5c0-.828-.672-1.5-1.5-1.5S4 13.672 4 14.5 4.672 16 5.5 16 7 15.328 7 14.5z"})));break;case"gridicons-create":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M21 14v5c0 1.105-.895 2-2 2H5c-1.105 0-2-.895-2-2V5c0-1.105.895-2 2-2h5v2H5v14h14v-5h2z"}),i.default.createElement("path",{d:"M21 7h-4V3h-2v4h-4v2h4v4h2V9h4"})));break;case"gridicons-credit-card":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 4H4c-1.105 0-2 .895-2 2v12c0 1.105.895 2 2 2h16c1.105 0 2-.895 2-2V6c0-1.105-.895-2-2-2zm0 2v2H4V6h16zM4 18v-6h16v6H4zm2-4h7v2H6v-2zm9 0h3v2h-3v-2z"})));break;case"gridicons-crop":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M22 16h-4V8c0-1.105-.895-2-2-2H8V2H6v4H2v2h4v8c0 1.105.895 2 2 2h8v4h2v-4h4v-2zM8 16V8h8v8H8z"})));break;case"gridicons-cross-circle":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M19.1 4.9C15.2 1 8.8 1 4.9 4.9S1 15.2 4.9 19.1s10.2 3.9 14.1 0 4-10.3.1-14.2zm-4.3 11.3L12 13.4l-2.8 2.8-1.4-1.4 2.8-2.8-2.8-2.8 1.4-1.4 2.8 2.8 2.8-2.8 1.4 1.4-2.8 2.8 2.8 2.8-1.4 1.4z"})));break;case"gridicons-cross-small":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.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"})));break;case"gridicons-cross":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18.36 19.78L12 13.41l-6.36 6.37-1.42-1.42L10.59 12 4.22 5.64l1.42-1.42L12 10.59l6.36-6.36 1.41 1.41L13.41 12l6.36 6.36z"})));break;case"gridicons-custom-post-type":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M19 3H5c-1.105 0-2 .895-2 2v14c0 1.105.895 2 2 2h14c1.105 0 2-.895 2-2V5c0-1.105-.895-2-2-2zM6 6h5v5H6V6zm4.5 13C9.12 19 8 17.88 8 16.5S9.12 14 10.5 14s2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5zm3-6l3-5 3 5h-6z"})));break;case"gridicons-customize":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M2 6c0-1.505.78-3.08 2-4 0 .845.69 2 2 2 1.657 0 3 1.343 3 3 0 .386-.08.752-.212 1.09.74.594 1.476 1.19 2.19 1.81L8.9 11.98c-.62-.716-1.214-1.454-1.807-2.192C6.753 9.92 6.387 10 6 10c-2.21 0-4-1.79-4-4zm12.152 6.848l1.34-1.34c.607.304 1.283.492 2.008.492 2.485 0 4.5-2.015 4.5-4.5 0-.725-.188-1.4-.493-2.007L18 9l-2-2 3.507-3.507C18.9 3.188 18.225 3 17.5 3 15.015 3 13 5.015 13 7.5c0 .725.188 1.4.493 2.007L3 20l2 2 6.848-6.848c1.885 1.928 3.874 3.753 5.977 5.45l1.425 1.148 1.5-1.5-1.15-1.425c-1.695-2.103-3.52-4.092-5.448-5.977z"})));break;case"gridicons-domains":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm6.918 6h-3.215c-.188-1.424-.42-2.65-.565-3.357 1.593.682 2.916 1.87 3.78 3.357zm-5.904-3.928c.068.352.387 2.038.645 3.928h-3.32c.26-1.89.578-3.576.646-3.928C11.32 4.03 11.656 4 12 4s.68.03 1.014.072zM14 12c0 .598-.043 1.286-.11 2h-3.78c-.067-.714-.11-1.402-.11-2s.043-1.286.11-2h3.78c.067.714.11 1.402.11 2zM8.862 4.643C8.717 5.35 8.485 6.576 8.297 8H5.082c.864-1.487 2.187-2.675 3.78-3.357zM4.262 10h3.822c-.05.668-.084 1.344-.084 2s.033 1.332.085 2H4.263C4.097 13.36 4 12.692 4 12s.098-1.36.263-2zm.82 6h3.215c.188 1.424.42 2.65.565 3.357-1.593-.682-2.916-1.87-3.78-3.357zm5.904 3.928c-.068-.353-.388-2.038-.645-3.928h3.32c-.26 1.89-.578 3.576-.646 3.928-.333.043-.67.072-1.014.072s-.68-.03-1.014-.072zm4.152-.57c.145-.708.377-1.934.565-3.358h3.215c-.864 1.487-2.187 2.675-3.78 3.357zm4.6-5.358h-3.822c.05-.668.084-1.344.084-2s-.033-1.332-.085-2h3.82c.167.64.265 1.308.265 2s-.097 1.36-.263 2z"})));break;case"gridicons-dropdown":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M7 10l5 5 5-5"})));break;case"gridicons-ellipsis-circle":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10 10-4.5 10-10S17.5 2 12 2zM7.5 13.5c-.8 0-1.5-.7-1.5-1.5s.7-1.5 1.5-1.5S9 11.2 9 12s-.7 1.5-1.5 1.5zm4.5 0c-.8 0-1.5-.7-1.5-1.5s.7-1.5 1.5-1.5 1.5.7 1.5 1.5-.7 1.5-1.5 1.5zm4.5 0c-.8 0-1.5-.7-1.5-1.5s.7-1.5 1.5-1.5 1.5.7 1.5 1.5-.7 1.5-1.5 1.5z"})));break;case"gridicons-ellipsis":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M7 12c0 1.104-.896 2-2 2s-2-.896-2-2 .896-2 2-2 2 .896 2 2zm12-2c-1.104 0-2 .896-2 2s.896 2 2 2 2-.896 2-2-.896-2-2-2zm-7 0c-1.104 0-2 .896-2 2s.896 2 2 2 2-.896 2-2-.896-2-2-2z"})));break;case"gridicons-external":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M19 13v6c0 1.105-.895 2-2 2H5c-1.105 0-2-.895-2-2V7c0-1.105.895-2 2-2h6v2H5v12h12v-6h2zM13 3v2h4.586l-7.793 7.793 1.414 1.414L19 6.414V11h2V3h-8z"})));break;case"gridicons-filter":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18.595 4H5.415c-.552-.003-1.003.442-1.006.994-.002.27.104.527.295.716l5.3 5.29v6l4 4V11l5.29-5.29c.392-.39.395-1.022.006-1.414-.186-.188-.44-.295-.705-.296z"})));break;case"gridicons-flag":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M15 6c0-1.105-.895-2-2-2H5v17h2v-7h5c0 1.105.895 2 2 2h6V6h-5z"})));break;case"gridicons-flip-horizontal":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 18v-5h3v-2h-3V6c0-1.105-.895-2-2-2H6c-1.105 0-2 .895-2 2v5H1v2h3v5c0 1.105.895 2 2 2h12c1.105 0 2-.895 2-2zM6 6h12v5H6V6z"})));break;case"gridicons-flip-vertical":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 4h-5V1h-2v3H6c-1.105 0-2 .895-2 2v12c0 1.105.895 2 2 2h5v3h2v-3h5c1.105 0 2-.895 2-2V6c0-1.105-.895-2-2-2zM6 18V6h5v12H6z"})));break;case"gridicons-folder-multiple":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M4 8c-1.105 0-2 .895-2 2v10c0 1.1.9 2 2 2h14c1.105 0 2-.895 2-2H4V8zm16 10H8c-1.105 0-2-.895-2-2V6c0-1.105.895-2 2-2h3c1.105 0 2 .895 2 2h7c1.105 0 2 .895 2 2v8c0 1.105-.895 2-2 2z"})));break;case"gridicons-folder":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 19H6c-1.1 0-2-.9-2-2V7c0-1.1.9-2 2-2h3c1.1 0 2 .9 2 2h7c1.1 0 2 .9 2 2v8c0 1.1-.9 2-2 2z"})));break;case"gridicons-fullscreen-exit":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M14 10V4h2v2.59l3.29-3.29 1.41 1.41L17.41 8H20v2zM4 10V8h2.59l-3.3-3.29 1.42-1.42L8 6.59V4h2v6zm16 4v2h-2.59l3.29 3.29-1.41 1.41L16 17.41V20h-2v-6zm-10 0v6H8v-2.59l-3.29 3.3-1.42-1.42L6.59 16H4v-2z"})));break;case"gridicons-fullscreen":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M21 3v6h-2V6.41l-3.29 3.3-1.42-1.42L17.59 5H15V3zM3 3v6h2V6.41l3.29 3.3 1.42-1.42L6.41 5H9V3zm18 18v-6h-2v2.59l-3.29-3.29-1.41 1.41L17.59 19H15v2zM9 21v-2H6.41l3.29-3.29-1.41-1.42L5 17.59V15H3v6z"})));break;case"gridicons-gift":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M22 6h-4.8c.5-.5.8-1.2.8-2 0-1.7-1.3-3-3-3s-3 1.3-3 3c0-1.7-1.3-3-3-3S6 2.3 6 4c0 .8.3 1.5.8 2H2v6h1v8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-8h1V6zm-2 4h-7V8h7v2zm-5-7c.6 0 1 .4 1 1s-.4 1-1 1-1-.4-1-1 .4-1 1-1zM9 3c.6 0 1 .4 1 1s-.4 1-1 1-1-.4-1-1 .4-1 1-1zM4 8h7v2H4V8zm1 4h6v8H5v-8zm14 8h-6v-8h6v8z"})));break;case"gridicons-globe":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm0 18l2-2 1-1v-2h-2v-1l-1-1H9v3l2 2v1.93c-3.94-.494-7-3.858-7-7.93l1 1h2v-2h2l3-3V6h-2L9 5v-.41C9.927 4.21 10.94 4 12 4s2.073.212 3 .59V6l-1 1v2l1 1 3.13-3.13c.752.897 1.304 1.964 1.606 3.13H18l-2 2v2l1 1h2l.286.286C18.03 18.06 15.24 20 12 20z"})));break;case"gridicons-grid":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M8 8H4V4h4v4zm6-4h-4v4h4V4zm6 0h-4v4h4V4zM8 10H4v4h4v-4zm6 0h-4v4h4v-4zm6 0h-4v4h4v-4zM8 16H4v4h4v-4zm6 0h-4v4h4v-4zm6 0h-4v4h4v-4z"})));break;case"gridicons-heading-h1":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M11 7h2v10h-2v-4H7v4H5V7h2v4h4V7zm6.57 0c-.594.95-1.504 1.658-2.57 2v1h2v7h2V7h-1.43z"})));break;case"gridicons-heading-h2":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M9 7h2v10H9v-4H5v4H3V7h2v4h4V7zm8 8c.51-.41.6-.62 1.06-1.05.437-.4.848-.828 1.23-1.28.334-.39.62-.82.85-1.28.2-.39.305-.822.31-1.26.005-.44-.087-.878-.27-1.28-.177-.385-.437-.726-.76-1-.346-.283-.743-.497-1.17-.63-.485-.153-.99-.227-1.5-.22-.36 0-.717.033-1.07.1-.343.06-.678.158-1 .29-.304.13-.593.295-.86.49-.287.21-.56.437-.82.68l1.24 1.22c.308-.268.643-.502 1-.7.35-.2.747-.304 1.15-.3.455-.03.906.106 1.27.38.31.278.477.684.45 1.1-.014.396-.14.78-.36 1.11-.285.453-.62.872-1 1.25-.44.43-.98.92-1.59 1.43-.61.51-1.41 1.06-2.16 1.65V17h8v-2h-4z"})));break;case"gridicons-heading-h3":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M14.11 14.218c.355.287.75.523 1.17.7.434.18.9.273 1.37.27.484.017.965-.086 1.4-.3.333-.146.55-.476.55-.84.003-.203-.05-.403-.15-.58-.123-.19-.3-.34-.51-.43-.32-.137-.655-.228-1-.27-.503-.073-1.012-.106-1.52-.1v-1.57c.742.052 1.485-.07 2.17-.36.37-.164.615-.525.63-.93.026-.318-.12-.627-.38-.81-.34-.203-.734-.3-1.13-.28-.395.013-.784.108-1.14.28-.375.167-.73.375-1.06.62l-1.22-1.39c.5-.377 1.053-.68 1.64-.9.608-.224 1.252-.336 1.9-.33.525-.007 1.05.05 1.56.17.43.1.84.277 1.21.52.325.21.595.495.79.83.19.342.287.73.28 1.12.01.48-.177.943-.52 1.28-.417.39-.916.685-1.46.86v.06c.61.14 1.175.425 1.65.83.437.382.68.94.66 1.52.005.42-.113.835-.34 1.19-.23.357-.538.657-.9.88-.408.253-.853.44-1.32.55-.514.128-1.04.192-1.57.19-.786.02-1.57-.106-2.31-.37-.59-.214-1.126-.556-1.57-1l1.12-1.41zM9 11H5V7H3v10h2v-4h4v4h2V7H9v4z"})));break;case"gridicons-heading-h4":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M11 17H9v-4H5v4H3V7h2v4h4V7h2v10zm10-2h-1v2h-2v-2h-5v-2l4.05-6H20v6h1v2zm-3-2V9l-2.79 4H18z"})));break;case"gridicons-heading-h5":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M14.09 14.19c.352.27.73.5 1.13.69.42.196.877.296 1.34.29.51.014 1.01-.125 1.44-.4.378-.253.594-.686.57-1.14.02-.45-.197-.877-.57-1.13-.406-.274-.89-.41-1.38-.39h-.47c-.135.014-.27.04-.4.08l-.41.15-.48.23-1.02-.57.28-5h6.4v1.92h-4.31L16 10.76c.222-.077.45-.138.68-.18.235-.037.472-.054.71-.05.463-.004.924.057 1.37.18.41.115.798.305 1.14.56.33.248.597.57.78.94.212.422.322.888.32 1.36.007.497-.11.99-.34 1.43-.224.417-.534.782-.91 1.07-.393.3-.837.527-1.31.67-.497.164-1.016.252-1.54.26-.788.023-1.573-.11-2.31-.39-.584-.238-1.122-.577-1.59-1l1.09-1.42zM11 17H9v-4H5v4H3V7h2v4h4V7h2v10z"})));break;case"gridicons-heading-h6":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M11 17H9v-4H5v4H3V7h2v4h4V7h2v10zm8.58-7.508c-.248-.204-.524-.37-.82-.49-.625-.242-1.317-.242-1.94 0-.3.11-.566.287-.78.52-.245.27-.432.586-.55.93-.16.46-.243.943-.25 1.43.367-.33.79-.59 1.25-.77.405-.17.84-.262 1.28-.27.415-.006.83.048 1.23.16.364.118.704.304 1 .55.295.253.528.57.68.93.193.403.302.843.32 1.29.01.468-.094.93-.3 1.35-.206.387-.49.727-.83 1-.357.287-.764.504-1.2.64-.98.31-2.033.293-3-.05-.507-.182-.968-.472-1.35-.85-.437-.416-.778-.92-1-1.48-.243-.693-.352-1.426-.32-2.16-.02-.797.11-1.59.38-2.34.215-.604.556-1.156 1-1.62.406-.416.897-.74 1.44-.95.54-.21 1.118-.314 1.7-.31.682-.02 1.36.096 2 .34.5.19.962.464 1.37.81l-1.31 1.34zm-2.39 5.84c.202 0 .405-.03.6-.09.183-.046.356-.128.51-.24.15-.136.27-.303.35-.49.092-.225.136-.467.13-.71.037-.405-.123-.804-.43-1.07-.328-.23-.72-.347-1.12-.33-.346-.002-.687.07-1 .21-.383.17-.724.418-1 .73.046.346.143.683.29 1 .108.23.257.44.44.62.152.15.337.26.54.33.225.055.46.068.69.04z"})));break;case"gridicons-heading":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 20h-3v-6H9v6H6V5.01h3V11h6V5.01h3V20z"})));break;case"gridicons-heart-outline":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M16.5 4.5c2.206 0 4 1.794 4 4 0 4.67-5.543 8.94-8.5 11.023C9.043 17.44 3.5 13.17 3.5 8.5c0-2.206 1.794-4 4-4 1.298 0 2.522.638 3.273 1.706L12 7.953l1.227-1.746c.75-1.07 1.975-1.707 3.273-1.707m0-1.5c-1.862 0-3.505.928-4.5 2.344C11.005 3.928 9.362 3 7.5 3 4.462 3 2 5.462 2 8.5c0 5.72 6.5 10.438 10 12.85 3.5-2.412 10-7.13 10-12.85C22 5.462 19.538 3 16.5 3z"})));break;case"gridicons-heart":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M16.5 3c-1.862 0-3.505.928-4.5 2.344C11.005 3.928 9.362 3 7.5 3 4.462 3 2 5.462 2 8.5c0 5.72 6.5 10.438 10 12.85 3.5-2.412 10-7.13 10-12.85C22 5.462 19.538 3 16.5 3z"})));break;case"gridicons-help-outline":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 4c4.41 0 8 3.59 8 8s-3.59 8-8 8-8-3.59-8-8 3.59-8 8-8m0-2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm4 8c0-2.21-1.79-4-4-4s-4 1.79-4 4h2c0-1.103.897-2 2-2s2 .897 2 2-.897 2-2 2c-.552 0-1 .448-1 1v2h2v-1.14c1.722-.447 3-1.998 3-3.86zm-3 6h-2v2h2v-2z"})));break;case"gridicons-help":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm1 16h-2v-2h2v2zm0-4.14V15h-2v-2c0-.552.448-1 1-1 1.103 0 2-.897 2-2s-.897-2-2-2-2 .897-2 2H8c0-2.21 1.79-4 4-4s4 1.79 4 4c0 1.862-1.278 3.413-3 3.86z"})));break;case"gridicons-history":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M2.12 13.526c.742 4.78 4.902 8.47 9.88 8.47 5.5 0 10-4.5 10-9.998S17.5 2 12 2C8.704 2 5.802 3.6 4 6V2H2.003L2 9h7V7H5.8c1.4-1.8 3.702-3 6.202-3C16.4 4 20 7.6 20 11.998s-3.6 8-8 8c-3.877 0-7.13-2.795-7.848-6.472H2.12z"}),i.default.createElement("path",{d:"M11.002 7v5.3l3.2 4.298 1.6-1.197-2.8-3.7V7"})));break;case"gridicons-house":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M22 9L12 1 2 9v2h2v10h5v-4c0-1.657 1.343-3 3-3s3 1.343 3 3v4h5V11h2V9z"})));break;case"gridicons-image-multiple":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M15 7.5c0-.828.672-1.5 1.5-1.5s1.5.672 1.5 1.5S17.328 9 16.5 9 15 8.328 15 7.5zM4 20h14c0 1.105-.895 2-2 2H4c-1.1 0-2-.9-2-2V8c0-1.105.895-2 2-2v14zM22 4v12c0 1.105-.895 2-2 2H8c-1.105 0-2-.895-2-2V4c0-1.105.895-2 2-2h12c1.105 0 2 .895 2 2zM8 4v6.333L11 7l4.855 5.395.656-.73c.796-.886 2.183-.886 2.977 0l.513.57V4H8z"})));break;case"gridicons-image-remove":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20.587 3.423L22 4.837 20 6.84V18c0 1.105-.895 2-2 2H6.84l-2.007 2.006-1.414-1.414 17.167-17.17zM12.42 14.42l1 1 1-1c.63-.504 1.536-.456 2.11.11L18 16V8.84l-5.58 5.58zM15.16 6H6v6.38l2.19-2.19 1.39 1.39L4 17.163V6c0-1.105.895-2 2-2h11.162l-2 2z"})));break;case"gridicons-image":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 6v12c0 1.105-.895 2-2 2H6c-1.105 0-2-.895-2-2V6c0-1.105.895-2 2-2h12c1.105 0 2 .895 2 2zm-2 0H6v6.38l2.19-2.19 5.23 5.23 1-1c.63-.504 1.536-.456 2.11.11L18 16V6zm-5 3.5c0-.828.672-1.5 1.5-1.5s1.5.672 1.5 1.5-.672 1.5-1.5 1.5-1.5-.672-1.5-1.5z"})));break;case"gridicons-indent-left":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 20h2V4h-2v16zM2 11h10.172l-2.086-2.086L11.5 7.5 16 12l-4.5 4.5-1.414-1.414L12.172 13H2v-2z"})));break;case"gridicons-indent-right":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M6 4H4v16h2V4zm16 9H11.828l2.086 2.086L12.5 16.5 8 12l4.5-4.5 1.414 1.414L11.828 11H22v2z"})));break;case"gridicons-info-outline":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M13 9h-2V7h2v2zm0 2h-2v6h2v-6zm-1-7c-4.41 0-8 3.59-8 8s3.59 8 8 8 8-3.59 8-8-3.59-8-8-8m0-2c5.523 0 10 4.477 10 10s-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2z"})));break;case"gridicons-info":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"})));break;case"gridicons-ink":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M5 15c0 3.866 3.134 7 7 7s7-3.134 7-7c0-1.387-.41-2.677-1.105-3.765h.007L12 2l-5.903 9.235h.007C5.41 12.323 5 13.613 5 15z"})));break;case"gridicons-institution":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M2 19h20v3H2zM12 2L2 6v2h20V6M17 10h3v7h-3zM10.5 10h3v7h-3zM4 10h3v7H4z"})));break;case"gridicons-italic":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M10.536 5l-.427 2h1.5L9.262 18h-1.5l-.427 2h6.128l.426-2h-1.5l2.347-11h1.5l.427-2"})));break;case"gridicons-layout-blocks":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M21 7h-2V3c0-1.105-.895-2-2-2H7c-1.105 0-2 .895-2 2v2H3c-1.105 0-2 .895-2 2v4c0 1.105.895 2 2 2h2v8c0 1.105.895 2 2 2h10c1.105 0 2-.895 2-2v-2h2c1.105 0 2-.895 2-2V9c0-1.105-.895-2-2-2zm-4 14H7v-8h2c1.105 0 2-.895 2-2V7c0-1.105-.895-2-2-2H7V3h10v4h-2c-1.105 0-2 .895-2 2v8c0 1.105.895 2 2 2h2v2zm4-4h-6V9h6v8z"})));break;case"gridicons-layout":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M8 20H5c-1.105 0-2-.895-2-2V6c0-1.105.895-2 2-2h3c1.105 0 2 .895 2 2v12c0 1.105-.895 2-2 2zm8-10h4c1.105 0 2-.895 2-2V5c0-1.105-.895-2-2-2h-4c-1.105 0-2 .895-2 2v3c0 1.105.895 2 2 2zm5 10v-6c0-1.105-.895-2-2-2h-5c-1.105 0-2 .895-2 2v6c0 1.105.895 2 2 2h5c1.105 0 2-.895 2-2z"})));break;case"gridicons-link-break":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M10 11l-2 2H7v-2h3zm9.64-3.64L22 5l-1.5-1.5-17 17L5 22l9-9h3v-2h-1l2-2c1.103 0 2 .897 2 2v2c0 1.103-.897 2-2 2h-4.977c.913 1.208 2.347 2 3.977 2h1c2.21 0 4-1.79 4-4v-2c0-1.623-.97-3.013-2.36-3.64zM4.36 16.64L6 15c-1.103 0-2-.897-2-2v-2c0-1.103.897-2 2-2h4.977C10.065 7.792 8.63 7 7 7H6c-2.21 0-4 1.79-4 4v2c0 1.623.97 3.013 2.36 3.64z"})));break;case"gridicons-link":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M17 13H7v-2h10v2zm1-6h-1c-1.63 0-3.065.792-3.977 2H18c1.103 0 2 .897 2 2v2c0 1.103-.897 2-2 2h-4.977c.913 1.208 2.347 2 3.977 2h1c2.21 0 4-1.79 4-4v-2c0-2.21-1.79-4-4-4zM2 11v2c0 2.21 1.79 4 4 4h1c1.63 0 3.065-.792 3.977-2H6c-1.103 0-2-.897-2-2v-2c0-1.103.897-2 2-2h4.977C10.065 7.792 8.63 7 7 7H6c-2.21 0-4 1.79-4 4z"})));break;case"gridicons-list-checkmark":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M9.5 15.5L5 20l-2.5-2.5 1.06-1.06L5 17.88l3.44-3.44L9.5 15.5zM10 5v2h11V5H10zm0 14h11v-2H10v2zm0-6h11v-2H10v2zM8.44 8.44L5 11.88l-1.44-1.44L2.5 11.5 5 14l4.5-4.5-1.06-1.06zm0-6L5 5.88 3.56 4.44 2.5 5.5 5 8l4.5-4.5-1.06-1.06z"})));break;case"gridicons-list-ordered":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M8 19h13v-2H8v2zm0-6h13v-2H8v2zm0-8v2h13V5H8zm-4.425.252c.107-.096.197-.188.27-.275-.013.228-.02.48-.02.756V8h1.176V3.717H3.96L2.487 4.915l.6.738.487-.4zm.334 7.764c.474-.426.784-.715.93-.867.145-.153.26-.298.35-.436.087-.138.152-.278.194-.42.042-.143.063-.298.063-.466 0-.225-.06-.427-.18-.608s-.29-.32-.507-.417c-.218-.1-.465-.148-.742-.148-.22 0-.42.022-.596.067s-.34.11-.49.195c-.15.085-.337.226-.558.423l.636.744c.174-.15.33-.264.467-.34.138-.078.274-.117.41-.117.13 0 .232.032.304.097.073.064.11.152.11.264 0 .09-.02.176-.055.258-.036.082-.1.18-.192.294-.092.114-.287.328-.586.64L2.42 13.238V14h3.11v-.955H3.91v-.03zm.53 4.746v-.018c.306-.086.54-.225.702-.414.162-.19.243-.42.243-.685 0-.31-.126-.55-.378-.727-.252-.176-.6-.264-1.043-.264-.307 0-.58.033-.816.1s-.47.178-.696.334l.48.773c.293-.183.576-.274.85-.274.147 0 .263.027.35.082s.13.14.13.252c0 .3-.294.45-.882.45h-.27v.87h.264c.217 0 .393.017.527.05.136.03.233.08.294.143.06.064.09.154.09.27 0 .153-.057.265-.173.337-.115.07-.3.106-.554.106-.164 0-.343-.022-.538-.07-.194-.044-.385-.115-.573-.21v.96c.228.088.44.148.637.182.196.033.41.05.64.05.56 0 .998-.114 1.314-.343.315-.228.473-.542.473-.94.002-.585-.356-.923-1.07-1.013z"})));break;case"gridicons-list-unordered":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M9 19h12v-2H9v2zm0-6h12v-2H9v2zm0-8v2h12V5H9zm-4-.5c-.828 0-1.5.672-1.5 1.5S4.172 7.5 5 7.5 6.5 6.828 6.5 6 5.828 4.5 5 4.5zm0 6c-.828 0-1.5.672-1.5 1.5s.672 1.5 1.5 1.5 1.5-.672 1.5-1.5-.672-1.5-1.5-1.5zm0 6c-.828 0-1.5.672-1.5 1.5s.672 1.5 1.5 1.5 1.5-.672 1.5-1.5-.672-1.5-1.5-1.5z"})));break;case"gridicons-location":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M19 9c0-3.866-3.134-7-7-7S5 5.134 5 9c0 1.387.41 2.677 1.105 3.765h-.008C8.457 16.46 12 22 12 22l5.903-9.235h-.007C18.59 11.677 19 10.387 19 9zm-7 3c-1.657 0-3-1.343-3-3s1.343-3 3-3 3 1.343 3 3-1.343 3-3 3z"})));break;case"gridicons-lock":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 8h-1V7c0-2.757-2.243-5-5-5S7 4.243 7 7v1H6c-1.105 0-2 .895-2 2v10c0 1.105.895 2 2 2h12c1.105 0 2-.895 2-2V10c0-1.105-.895-2-2-2zM9 7c0-1.654 1.346-3 3-3s3 1.346 3 3v1H9V7zm4 8.723V18h-2v-2.277c-.595-.346-1-.984-1-1.723 0-1.105.895-2 2-2s2 .895 2 2c0 .738-.405 1.376-1 1.723z"})));break;case"gridicons-mail":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 4H4c-1.105 0-2 .895-2 2v12c0 1.105.895 2 2 2h16c1.105 0 2-.895 2-2V6c0-1.105-.895-2-2-2zm0 4.236l-8 4.882-8-4.882V6h16v2.236z"})));break;case"gridicons-media-google":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M17.4 8.7c.3-.5 1-2.8 1.3-4.1C16.9 3 14.6 2 12 2c-1.4 0-2.8.3-4 .8l8.2 6s.7.7 1.2-.1zM10.5 6c-.4-.5-2.5-1.9-3.6-2.6C4 5.1 2 8.3 2 12c0 .4 0 .7.1 1.1l8.2-5.9s.8-.5.2-1.2zm-4.7 5.7c-.5.2-2.5 1.7-3.6 2.5C3 18 6 20.9 9.7 21.8l-2.9-9.5c0-.1-.2-1-1-.6zm4 6.2c.1.6.8 2.7 1.3 4.1h.9c3.6 0 6.8-2 8.6-4.9h-9.9s-1-.1-.9.8zm9.7-12.5l-3.1 9.5s-.4.9.5 1.1c.6.1 2.8.1 4.2 0 .5-1.2.8-2.6.8-4 .1-2.5-.8-4.8-2.4-6.6z"})));break;case"gridicons-mention":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2a10 10 0 0 0 0 20v-2a8 8 0 1 1 8-8v.5a1.5 1.5 0 0 1-3 0V7h-2v1a5 5 0 1 0 1 7 3.5 3.5 0 0 0 6-2.46V12A10 10 0 0 0 12 2zm0 13a3 3 0 1 1 3-3 3 3 0 0 1-3 3z"})));break;case"gridicons-menu":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M21 6v2H3V6h18zM3 18h18v-2H3v2zm0-5h18v-2H3v2z"})));break;case"gridicons-menus":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M9 19h10v-2H9v2zm0-6h6v-2H9v2zm0-8v2h12V5H9zm-4-.5c-.828 0-1.5.672-1.5 1.5S4.172 7.5 5 7.5 6.5 6.828 6.5 6 5.828 4.5 5 4.5zm0 6c-.828 0-1.5.672-1.5 1.5s.672 1.5 1.5 1.5 1.5-.672 1.5-1.5-.672-1.5-1.5-1.5zm0 6c-.828 0-1.5.672-1.5 1.5s.672 1.5 1.5 1.5 1.5-.672 1.5-1.5-.672-1.5-1.5-1.5z"})));break;case"gridicons-microphone":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M19 9v1a7 7 0 0 1-6 6.92V20h3v2H8v-2h3v-3.08A7 7 0 0 1 5 10V9h2v1a5 5 0 0 0 10 0V9zm-7 4a3 3 0 0 0 3-3V5a3 3 0 0 0-6 0v5a3 3 0 0 0 3 3z"})));break;case"gridicons-minus-small":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M6 11h12v2H6z"})));break;case"gridicons-minus":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M3 11h18v2H3z"})));break;case"gridicons-money":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M2 5v14h20V5H2zm5 12c0-1.657-1.343-3-3-3v-4c1.657 0 3-1.343 3-3h10c0 1.657 1.343 3 3 3v4c-1.657 0-3 1.343-3 3H7zm5-8c1.1 0 2 1.3 2 3s-.9 3-2 3-2-1.3-2-3 .9-3 2-3z"})));break;case"gridicons-my-sites-horizon":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M10.986 13.928l.762-2.284-1.324-3.63c-.458-.026-.892-.08-.892-.08-.458-.027-.405-.727.054-.7 0 0 1.403.107 2.24.107.888 0 2.265-.107 2.265-.107.46-.027.513.646.055.7 0 0-.46.055-.973.082l2.006 5.966c-.875-.034-1.74-.053-2.6-.06l-.428-1.177-.403 1.17c-.252.002-.508.01-.76.015zm-7.156.393c-.21-.737-.33-1.514-.33-2.32 0-1.232.264-2.402.736-3.46l2.036 5.58c.85-.06 1.69-.104 2.526-.138L6.792 8.015c.512-.027.973-.08.973-.08.458-.055.404-.728-.055-.702 0 0-1.376.108-2.265.108-.16 0-.347-.003-.547-.01C6.418 5.025 9.03 3.5 12 3.5c2.213 0 4.228.846 5.74 2.232-.036-.002-.072-.007-.11-.007-.835 0-1.427.727-1.427 1.51 0 .7.404 1.292.835 1.993.323.566.7 1.293.7 2.344 0 .674-.244 1.463-.572 2.51.3.02.604.043.907.066l.798-2.307c.486-1.212.647-2.18.647-3.043 0-.313-.02-.603-.057-.874.662 1.21 1.04 2.6 1.04 4.077 0 .807-.128 1.58-.34 2.32.5.05 1.006.112 1.51.17.205-.798.33-1.628.33-2.49 0-5.523-4.477-10-10-10S2 6.477 2 12c0 .862.125 1.692.33 2.49.5-.057 1.003-.12 1.5-.17zm14.638 3.168C16.676 19.672 14.118 20.5 12 20.5c-1.876 0-4.55-.697-6.463-3.012-.585.048-1.174.1-1.77.16C5.572 20.272 8.578 22 12 22c3.422 0 6.43-1.73 8.232-4.35-.593-.063-1.18-.114-1.764-.162zM12 15.01c-3.715 0-7.368.266-10.958.733.18.41.35.825.506 1.247 3.427-.43 6.91-.68 10.452-.68s7.025.25 10.452.68c.156-.422.327-.836.506-1.246-3.59-.467-7.243-.734-10.958-.734z"})));break;case"gridicons-my-sites":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zM3.5 12c0-1.232.264-2.402.736-3.46L8.29 19.65C5.456 18.272 3.5 15.365 3.5 12zm8.5 8.5c-.834 0-1.64-.12-2.4-.345l2.55-7.41 2.613 7.157c.017.042.038.08.06.117-.884.31-1.833.48-2.823.48zm1.172-12.485c.512-.027.973-.08.973-.08.458-.055.404-.728-.054-.702 0 0-1.376.108-2.265.108-.835 0-2.24-.107-2.24-.107-.458-.026-.51.674-.053.7 0 0 .434.055.892.082l1.324 3.63-1.86 5.578-3.096-9.208c.512-.027.973-.08.973-.08.458-.055.403-.728-.055-.702 0 0-1.376.108-2.265.108-.16 0-.347-.003-.547-.01C6.418 5.025 9.03 3.5 12 3.5c2.213 0 4.228.846 5.74 2.232-.037-.002-.072-.007-.11-.007-.835 0-1.427.727-1.427 1.51 0 .7.404 1.292.835 1.993.323.566.7 1.293.7 2.344 0 .727-.28 1.572-.646 2.748l-.848 2.833-3.072-9.138zm3.1 11.332l2.597-7.506c.484-1.212.645-2.18.645-3.044 0-.313-.02-.603-.057-.874.664 1.21 1.042 2.6 1.042 4.078 0 3.136-1.7 5.874-4.227 7.347z"})));break;case"gridicons-nametag":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 6a1 1 0 1 1-1 1 1 1 0 0 1 1-1zm-6 8h12v3H6zm14-8h-4V3H8v3H4a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2zM10 5h4v5h-4zm10 14H4v-9h4a2 2 0 0 0 2 2h4a2 2 0 0 0 2-2h4z"})));break;case"gridicons-next-page":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 8h-8V6h8v2zm4-4v8l-6 6H8c-1.105 0-2-.895-2-2V4c0-1.105.895-2 2-2h12c1.105 0 2 .895 2 2zm-2 0H8v12h6v-4c0-1.105.895-2 2-2h4V4zM4 6c-1.105 0-2 .895-2 2v12c0 1.1.9 2 2 2h12c1.105 0 2-.895 2-2H4V6z"})));break;case"gridicons-not-visible":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M1 12s4.188-6 11-6c.947 0 1.84.12 2.678.322L8.36 12.64C8.133 12.14 8 11.586 8 11c0-.937.335-1.787.875-2.47C6.483 9.344 4.66 10.917 3.62 12c.68.707 1.696 1.62 2.98 2.398L5.15 15.85C2.498 14.13 1 12 1 12zm22 0s-4.188 6-11 6c-.946 0-1.836-.124-2.676-.323L5 22l-1.5-1.5 17-17L22 5l-3.147 3.147C21.5 9.87 23 12 23 12zm-2.615.006c-.678-.708-1.697-1.624-2.987-2.403L16 11c0 2.21-1.79 4-4 4l-.947.947c.31.03.624.053.947.053 3.978 0 6.943-2.478 8.385-3.994z"})));break;case"gridicons-notice-outline":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 4c4.41 0 8 3.59 8 8s-3.59 8-8 8-8-3.59-8-8 3.59-8 8-8m0-2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm1 13h-2v2h2v-2zm-2-2h2l.5-6h-3l.5 6z"})));break;case"gridicons-notice":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm1 15h-2v-2h2v2zm0-4h-2l-.5-6h3l-.5 6z"})));break;case"gridicons-offline":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M10 3h8l-4 6h4L6 21l4-9H6l4-9"})));break;case"gridicons-pages":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M16 8H8V6h8v2zm0 2H8v2h8v-2zm4-6v12l-6 6H6c-1.105 0-2-.895-2-2V4c0-1.105.895-2 2-2h12c1.105 0 2 .895 2 2zm-2 10V4H6v16h6v-4c0-1.105.895-2 2-2h4z"})));break;case"gridicons-pause":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm-1 14H9V8h2v8zm4 0h-2V8h2v8z"})));break;case"gridicons-pencil":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M13 6l5 5-9.507 9.507c-.686-.686-.69-1.794-.012-2.485l-.002-.003c-.69.676-1.8.673-2.485-.013-.677-.677-.686-1.762-.036-2.455l-.008-.008c-.694.65-1.78.64-2.456-.036L13 6zm7.586-.414l-2.172-2.172c-.78-.78-2.047-.78-2.828 0L14 5l5 5 1.586-1.586c.78-.78.78-2.047 0-2.828zM3 18v3h3c0-1.657-1.343-3-3-3z"})));break;case"gridicons-phone":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M16 2H8c-1.104 0-2 .896-2 2v16c0 1.104.896 2 2 2h8c1.104 0 2-.896 2-2V4c0-1.104-.896-2-2-2zm-3 19h-2v-1h2v1zm3-2H8V5h8v14z"})));break;case"gridicons-plans":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10 10-4.5 10-10S17.5 2 12 2zm-1 12H6l5-10v10zm2 6V10h5l-5 10z"})));break;case"gridicons-play":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2a10 10 0 1 0 10 10A10 10 0 0 0 12 2zm-2 14.5v-9l6 4.5z"})));break;case"gridicons-plugins":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M16 8V3c0-.552-.448-1-1-1s-1 .448-1 1v5h-4V3c0-.552-.448-1-1-1s-1 .448-1 1v5H5v4c0 2.79 1.637 5.193 4 6.317V22h6v-3.683c2.363-1.124 4-3.527 4-6.317V8h-3z"})));break;case"gridicons-plus-small":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 11h-5V6h-2v5H6v2h5v5h2v-5h5"})));break;case"gridicons-plus":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M21 13h-8v8h-2v-8H3v-2h8V3h2v8h8v2z"})));break;case"gridicons-popout":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M6 7V5c0-1.105.895-2 2-2h11c1.105 0 2 .895 2 2v14c0 1.105-.895 2-2 2H8c-1.105 0-2-.895-2-2v-2h2v2h11V5H8v2H6zm5.5-.5l-1.414 1.414L13.172 11H3v2h10.172l-3.086 3.086L11.5 17.5 17 12l-5.5-5.5z"})));break;case"gridicons-posts":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M16 19H3v-2h13v2zm5-10H3v2h18V9zM3 5v2h11V5H3zm14 0v2h4V5h-4zm-6 8v2h10v-2H11zm-8 0v2h5v-2H3z"})));break;case"gridicons-print":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M9 16h6v2H9v-2zm13 1h-3v3c0 1.105-.895 2-2 2H7c-1.105 0-2-.895-2-2v-3H2V9c0-1.105.895-2 2-2h1V5c0-1.105.895-2 2-2h10c1.105 0 2 .895 2 2v2h1c1.105 0 2 .895 2 2v8zM7 7h10V5H7v2zm10 7H7v6h10v-6zm3-3.5c0-.828-.672-1.5-1.5-1.5s-1.5.672-1.5 1.5.672 1.5 1.5 1.5 1.5-.672 1.5-1.5z"})));break;case"gridicons-product-downloadable":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M22 3H2v6h1v11c0 1.105.895 2 2 2h14c1.105 0 2-.895 2-2V9h1V3zM4 5h16v2H4V5zm15 15H5V9h14v11zm-6-10v5.17l2.59-2.58L17 14l-5 5-5-5 1.41-1.42L11 15.17V10h2z"})));break;case"gridicons-product-external":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M22 3H2v6h1v11c0 1.105.895 2 2 2h14c1.105 0 2-.895 2-2V9h1V3zM4 5h16v2H4V5zm15 15H5V9h14v11zm-2-9v6h-2v-2.59l-3.29 3.29-1.41-1.41L13.59 13H11v-2h6z"})));break;case"gridicons-product-virtual":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M22 3H2v6h1v11c0 1.105.895 2 2 2h14c1.105 0 2-.895 2-2V9h1V3zM4 5h16v2H4V5zm15 15H5V9h14v11zM7 16.45c0-1.005.815-1.82 1.82-1.82h.09c-.335-1.59.68-3.148 2.27-3.483s3.148.68 3.483 2.27c.02.097.036.195.046.293 1.252-.025 2.29.97 2.314 2.224.017.868-.462 1.67-1.235 2.066H7.87c-.54-.33-.87-.917-.87-1.55z"})));break;case"gridicons-product":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M22 3H2v6h1v11c0 1.105.895 2 2 2h14c1.105 0 2-.895 2-2V9h1V3zM4 5h16v2H4V5zm15 15H5V9h14v11zM9 11h6c0 1.105-.895 2-2 2h-2c-1.105 0-2-.895-2-2z"})));break;case"gridicons-quote":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M11.192 15.757c0-.88-.23-1.618-.69-2.217-.326-.412-.768-.683-1.327-.812-.55-.128-1.07-.137-1.54-.028-.16-.95.1-1.956.76-3.022.66-1.065 1.515-1.867 2.558-2.403L9.373 5c-.8.396-1.56.898-2.26 1.505-.71.607-1.34 1.305-1.9 2.094s-.98 1.68-1.25 2.69-.346 2.04-.217 3.1c.168 1.4.62 2.52 1.356 3.35.735.84 1.652 1.26 2.748 1.26.965 0 1.766-.29 2.4-.878.628-.576.94-1.365.94-2.368l.002.003zm9.124 0c0-.88-.23-1.618-.69-2.217-.326-.42-.77-.692-1.327-.817-.56-.124-1.074-.13-1.54-.022-.16-.94.09-1.95.75-3.02.66-1.06 1.514-1.86 2.557-2.4L18.49 5c-.8.396-1.555.898-2.26 1.505-.708.607-1.34 1.305-1.894 2.094-.556.79-.97 1.68-1.24 2.69-.273 1-.345 2.04-.217 3.1.165 1.4.615 2.52 1.35 3.35.732.833 1.646 1.25 2.742 1.25.967 0 1.768-.29 2.402-.876.627-.576.942-1.365.942-2.368v.01z"})));break;case"gridicons-read-more":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M9 12h6v-2H9zm-7 0h5v-2H2zm15 0h5v-2h-5zm3 2v2l-6 6H6a2 2 0 0 1-2-2v-6h2v6h6v-4a2 2 0 0 1 2-2h6zM4 8V4a2 2 0 0 1 2-2h12a2 2 0 0 1 2 2v4h-2V4H6v4z"})));break;case"gridicons-reader-follow-conversation":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 14v-3h-2v3h-3v2h3v3h2v-3h3v-2"}),i.default.createElement("path",{d:"M13 16h-2l-5 5v-5H4c-1.1 0-2-.9-2-2V5c0-1.1.9-2 2-2h14c1.1 0 2 .9 2 2v4h-4v3h-3v4z"})));break;case"gridicons-reader-follow":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M23 16v2h-3v3h-2v-3h-3v-2h3v-3h2v3h3zM20 2v9h-4v3h-3v4H4c-1.1 0-2-.9-2-2V2h18zM8 13v-1H4v1h4zm3-3H4v1h7v-1zm0-2H4v1h7V8zm7-4H4v2h14V4z"})));break;case"gridicons-reader-following-conversation":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M16.8 14.5l3.2-3.2V5c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v9c0 1.1.9 2 2 2h2v5l8.7-8.7 2.1 2.2z"}),i.default.createElement("path",{d:"M22.6 11.1l-6.1 6.1-2.1-2.2-1.4 1.4 3.5 3.6 7.5-7.6"})));break;case"gridicons-reader-following":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M23 13.482L15.508 21 12 17.4l1.412-1.388 2.106 2.188 6.094-6.094L23 13.482zm-7.455 1.862L20 10.89V2H2v14c0 1.1.9 2 2 2h4.538l4.913-4.832 2.095 2.176zM8 13H4v-1h4v1zm3-2H4v-1h7v1zm0-2H4V8h7v1zm7-3H4V4h14v2z"})));break;case"gridicons-reader":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M3 4v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V4H3zm7 11H5v-1h5v1zm2-2H5v-1h7v1zm0-2H5v-1h7v1zm7 4h-5v-5h5v5zm0-7H5V6h14v2z"})));break;case"gridicons-reblog":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M22.086 9.914L20 7.828V18c0 1.105-.895 2-2 2h-7v-2h7V7.828l-2.086 2.086L14.5 8.5 19 4l4.5 4.5-1.414 1.414zM6 16.172V6h7V4H6c-1.105 0-2 .895-2 2v10.172l-2.086-2.086L.5 15.5 5 20l4.5-4.5-1.414-1.414L6 16.172z"})));break;case"gridicons-redo":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 6v3.586L14.343 5.93C13.17 4.756 11.636 4.17 10.1 4.17s-3.07.585-4.242 1.757c-2.343 2.342-2.343 6.14 0 8.484l5.364 5.364 1.414-1.414L7.272 13c-1.56-1.56-1.56-4.097 0-5.657.755-.755 1.76-1.172 2.828-1.172 1.068 0 2.073.417 2.828 1.173L16.586 11H13v2h7V6h-2z"})));break;case"gridicons-refresh":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M17.91 14c-.478 2.833-2.943 5-5.91 5-3.308 0-6-2.692-6-6s2.692-6 6-6h2.172l-2.086 2.086L13.5 10.5 18 6l-4.5-4.5-1.414 1.414L14.172 5H12c-4.418 0-8 3.582-8 8s3.582 8 8 8c4.08 0 7.438-3.055 7.93-7h-2.02z"})));break;case"gridicons-refund":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M13.91 2.91L11.83 5H14c4.418 0 8 3.582 8 8h-2c0-3.314-2.686-6-6-6h-2.17l2.09 2.09-1.42 1.41L8 6l1.41-1.41L12.5 1.5l1.41 1.41zM2 12v10h16V12H2zm2 6.56v-3.11c.6-.35 1.1-.85 1.45-1.45h9.1c.35.6.85 1.1 1.45 1.45v3.11c-.593.35-1.085.845-1.43 1.44H5.45c-.35-.597-.85-1.094-1.45-1.44zm6 .44c.828 0 1.5-.895 1.5-2s-.672-2-1.5-2-1.5.895-1.5 2 .672 2 1.5 2z"})));break;case"gridicons-reply":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M9 16h7.2l-2.6 2.6L15 20l5-5-5-5-1.4 1.4 2.6 2.6H9c-2.2 0-4-1.8-4-4s1.8-4 4-4h2V4H9c-3.3 0-6 2.7-6 6s2.7 6 6 6z"})));break;case"gridicons-resize":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M13 4v2h3.59L6 16.59V13H4v7h7v-2H7.41L18 7.41V11h2V4h-7"})));break;case"gridicons-rotate":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 14v6c0 1.105-.895 2-2 2H6c-1.105 0-2-.895-2-2v-6c0-1.105.895-2 2-2h10c1.105 0 2 .895 2 2zM13.914 2.914L11.828 5H14c4.418 0 8 3.582 8 8h-2c0-3.308-2.692-6-6-6h-2.172l2.086 2.086L12.5 10.5 8 6l1.414-1.414L12.5 1.5l1.414 1.414z"})));break;case"gridicons-scheduled":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M10.498 18l-3.705-3.704 1.415-1.415 2.294 2.295 5.293-5.293 1.415 1.415L10.498 18zM21 6v13c0 1.104-.896 2-2 2H5c-1.104 0-2-.896-2-2V6c0-1.104.896-2 2-2h1V2h2v2h8V2h2v2h1c1.104 0 2 .896 2 2zm-2 2H5v11h14V8z"})));break;case"gridicons-search":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M21 19l-5.154-5.154C16.574 12.742 17 11.42 17 10c0-3.866-3.134-7-7-7s-7 3.134-7 7 3.134 7 7 7c1.42 0 2.742-.426 3.846-1.154L19 21l2-2zM5 10c0-2.757 2.243-5 5-5s5 2.243 5 5-2.243 5-5 5-5-2.243-5-5z"})));break;case"gridicons-share-computer":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 2H4a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h6v2H7v2h10v-2h-3v-2h6a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2zm0 14H4V4h16zm-3.25-3a1.75 1.75 0 0 1-3.5 0L10 11.36a1.71 1.71 0 1 1 0-2.71L13.25 7a1.77 1.77 0 1 1 .68 1.37L10.71 10l3.22 1.61A1.74 1.74 0 0 1 16.75 13z"})));break;case"gridicons-share-ios":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M17 8h2c1.105 0 2 .895 2 2v9c0 1.105-.895 2-2 2H5c-1.105 0-2-.895-2-2v-9c0-1.105.895-2 2-2h2v2H5v9h14v-9h-2V8zM6.5 5.5l1.414 1.414L11 3.828V14h2V3.828l3.086 3.086L17.5 5.5 12 0 6.5 5.5z"})));break;case"gridicons-share":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 16c-.788 0-1.5.31-2.034.807L8.91 12.7c.05-.23.09-.46.09-.7s-.04-.47-.09-.7l7.05-4.11c.54.5 1.25.81 2.04.81 1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3c0 .24.04.47.09.7L8.04 9.81C7.5 9.31 6.79 9 6 9c-1.66 0-3 1.34-3 3s1.34 3 3 3c.79 0 1.5-.31 2.04-.81l7.048 4.118c-.053.223-.088.453-.088.692 0 1.657 1.343 3 3 3s3-1.343 3-3-1.343-3-3-3z"})));break;case"gridicons-shipping":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 8h-2V7c0-1.105-.895-2-2-2H4c-1.105 0-2 .895-2 2v10h2c0 1.657 1.343 3 3 3s3-1.343 3-3h4c0 1.657 1.343 3 3 3s3-1.343 3-3h2v-5l-4-4zM7 18.5c-.828 0-1.5-.672-1.5-1.5s.672-1.5 1.5-1.5 1.5.672 1.5 1.5-.672 1.5-1.5 1.5zM4 14V7h10v7H4zm13 4.5c-.828 0-1.5-.672-1.5-1.5s.672-1.5 1.5-1.5 1.5.672 1.5 1.5-.672 1.5-1.5 1.5z"})));break;case"gridicons-shutter":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18.9 4.8s-.7 5.6-3.5 10.2c1.7-.3 3.9-.9 6.6-2 0 0 .7-4.6-3.1-8.2zm-6 2.8c-1.1-1.3-2.7-3-5-4.7C5.1 4.2 3 6.6 2.3 9.6 7 7.7 11 7.5 12.9 7.6zm3.4 2.9c.6-1.6 1.2-3.9 1.6-6.7-4.1-3-8.6-1.5-8.6-1.5s4.4 3.4 7 8.2zm-5.2 6c1.1 1.3 2.7 3 5 4.7 0 0 4.3-1.6 5.6-6.7 0-.1-5.3 2.1-10.6 2zm-3.4-3.1c-.6 1.6-1.2 3.8-1.5 6.7 0 0 3.6 2.9 8.6 1.5 0 0-4.6-3.4-7.1-8.2zM2 11.1s-.7 4.5 3.1 8.2c0 0 .7-5.7 3.5-10.3-1.7.3-4 .9-6.6 2.1z"})));break;case"gridicons-sign-out":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M16 17v2c0 1.105-.895 2-2 2H5c-1.105 0-2-.895-2-2V5c0-1.105.895-2 2-2h9c1.105 0 2 .895 2 2v2h-2V5H5v14h9v-2h2zm2.5-10.5l-1.414 1.414L20.172 11H10v2h10.172l-3.086 3.086L18.5 17.5 24 12l-5.5-5.5z"})));break;case"gridicons-spam":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M17 2H7L2 7v10l5 5h10l5-5V7l-5-5zm-4 15h-2v-2h2v2zm0-4h-2l-.5-6h3l-.5 6z"})));break;case"gridicons-speaker":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M19 8v6c1.7 0 3-1.3 3-3s-1.3-3-3-3zM11 7H4c-1.1 0-2 .9-2 2v4c0 1.1.9 2 2 2h1v3c0 1.1.9 2 2 2h2v-5h2l4 4h2V3h-2l-4 4z"})));break;case"gridicons-special-character":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12.005 7.418c-1.237 0-2.19.376-2.86 1.128s-1.005 1.812-1.005 3.18c0 1.387.226 2.513.677 3.377.45.865 1.135 1.543 2.05 2.036V20H5v-2.666h3.12c-1.04-.636-1.842-1.502-2.405-2.6-.564-1.097-.846-2.322-.846-3.676 0-1.258.29-2.363.875-3.317.585-.952 1.417-1.685 2.497-2.198s2.334-.77 3.763-.77c2.18 0 3.915.572 5.204 1.713s1.932 2.673 1.932 4.594c0 1.353-.283 2.57-.852 3.65-.567 1.08-1.38 1.947-2.44 2.603H19V20h-5.908v-2.86c.95-.493 1.65-1.18 2.102-2.062s.677-2.006.677-3.374c0-1.36-.336-2.415-1.01-3.164-.672-.747-1.624-1.122-2.855-1.122z"})));break;case"gridicons-star-outline":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 6.308l1.176 3.167.347.936.997.042 3.374.14-2.647 2.09-.784.62.27.963.91 3.25-2.813-1.872-.83-.553-.83.552-2.814 1.87.91-3.248.27-.962-.783-.62-2.648-2.092 3.374-.14.996-.04.347-.936L12 6.308M12 2L9.418 8.953 2 9.257l5.822 4.602L5.82 21 12 16.89 18.18 21l-2.002-7.14L22 9.256l-7.418-.305L12 2z"})));break;case"gridicons-star":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2l2.582 6.953L22 9.257l-5.822 4.602L18.18 21 12 16.89 5.82 21l2.002-7.14L2 9.256l7.418-.304"})));break;case"gridicons-stats-alt":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M21 21H3v-2h18v2zM8 10H4v7h4v-7zm6-7h-4v14h4V3zm6 3h-4v11h4V6z"})));break;case"gridicons-stats":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M19 3H5c-1.105 0-2 .895-2 2v14c0 1.105.895 2 2 2h14c1.105 0 2-.895 2-2V5c0-1.105-.895-2-2-2zm0 16H5V5h14v14zM9 17H7v-5h2v5zm4 0h-2V7h2v10zm4 0h-2v-7h2v7z"})));break;case"gridicons-status":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 4c4.41 0 8 3.59 8 8s-3.59 8-8 8-8-3.59-8-8 3.59-8 8-8m0-2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zM7.55 13c-.02.166-.05.33-.05.5 0 2.485 2.015 4.5 4.5 4.5s4.5-2.015 4.5-4.5c0-.17-.032-.334-.05-.5h-8.9zM10 10V8c0-.552-.448-1-1-1s-1 .448-1 1v2c0 .552.448 1 1 1s1-.448 1-1zm6 0V8c0-.552-.448-1-1-1s-1 .448-1 1v2c0 .552.448 1 1 1s1-.448 1-1z"})));break;case"gridicons-strikethrough":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M14.348 12H21v2h-4.613c.24.515.368 1.094.368 1.748 0 1.317-.474 2.355-1.423 3.114-.947.76-2.266 1.138-3.956 1.138-1.557 0-2.934-.293-4.132-.878v-2.874c.985.44 1.818.75 2.5.928.682.18 1.306.27 1.872.27.68 0 1.2-.13 1.562-.39.363-.26.545-.644.545-1.158 0-.285-.08-.54-.24-.763-.16-.222-.394-.437-.704-.643-.18-.12-.483-.287-.88-.49H3v-2H14.347zm-3.528-2c-.073-.077-.143-.155-.193-.235-.126-.202-.19-.44-.19-.713 0-.44.157-.795.47-1.068.313-.273.762-.41 1.348-.41.492 0 .993.064 1.502.19.51.127 1.153.35 1.93.67l1-2.405c-.753-.327-1.473-.58-2.16-.76-.69-.18-1.414-.27-2.173-.27-1.544 0-2.753.37-3.628 1.108-.874.738-1.312 1.753-1.312 3.044 0 .302.036.58.088.848h3.318z"})));break;case"gridicons-sync":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M23.5 13.5l-3.086 3.086L19 18l-4.5-4.5 1.414-1.414L18 14.172V12c0-3.308-2.692-6-6-6V4c4.418 0 8 3.582 8 8v2.172l2.086-2.086L23.5 13.5zM6 12V9.828l2.086 2.086L9.5 10.5 5 6 3.586 7.414.5 10.5l1.414 1.414L4 9.828V12c0 4.418 3.582 8 8 8v-2c-3.308 0-6-2.692-6-6z"})));break;case"gridicons-tablet":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 2H6c-1.104 0-2 .896-2 2v16c0 1.104.896 2 2 2h12c1.104 0 2-.896 2-2V4c0-1.104-.896-2-2-2zm-5 19h-2v-1h2v1zm5-2H6V5h12v14z"})));break;case"gridicons-tag":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M20 2.007h-7.087c-.53 0-1.04.21-1.414.586L2.592 11.5c-.78.78-.78 2.046 0 2.827l7.086 7.086c.78.78 2.046.78 2.827 0l8.906-8.906c.376-.374.587-.883.587-1.413V4.007c0-1.105-.895-2-2-2zM17.007 9c-1.105 0-2-.895-2-2s.895-2 2-2 2 .895 2 2-.895 2-2 2z"})));break;case"gridicons-text-color":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M3 19h18v3H3v-3zM15.82 17h3.424L14 3h-4L4.756 17H8.18l1.067-3.5h5.506L15.82 17zm-1.952-6h-3.73l1.868-5.725L13.868 11z"})));break;case"gridicons-themes":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M4 6c-1.105 0-2 .895-2 2v12c0 1.1.9 2 2 2h12c1.105 0 2-.895 2-2H4V6zm16-4H8c-1.105 0-2 .895-2 2v12c0 1.105.895 2 2 2h12c1.105 0 2-.895 2-2V4c0-1.105-.895-2-2-2zm-5 14H8V9h7v7zm5 0h-3V9h3v7zm0-9H8V4h12v3z"})));break;case"gridicons-thumbs-up":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M6.7 22H2v-9h2l2.7 9zM20 9h-6V5c0-1.657-1.343-3-3-3h-1v4L7.1 9.625c-.712.89-1.1 1.996-1.1 3.135V14l2.1 7h8.337c1.836 0 3.435-1.25 3.88-3.03l1.622-6.485C22.254 10.223 21.3 9 20 9z"})));break;case"gridicons-time":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 4c4.41 0 8 3.59 8 8s-3.59 8-8 8-8-3.59-8-8 3.59-8 8-8m0-2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm3.8 13.4L13 11.667V7h-2v5.333l3.2 4.266 1.6-1.2z"})));break;case"gridicons-trash":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M6.187 8h11.625l-.695 11.125C17.05 20.18 16.177 21 15.12 21H8.88c-1.057 0-1.93-.82-1.997-1.875L6.187 8zM19 5v2H5V5h3V4c0-1.105.895-2 2-2h4c1.105 0 2 .895 2 2v1h3zm-9 0h4V4h-4v1z"})));break;case"gridicons-trophy":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18 5.062V3H6v2.062H2V8c0 2.525 1.89 4.598 4.324 4.932.7 2.058 2.485 3.61 4.676 3.978V18c0 1.105-.895 2-2 2H8v2h8v-2h-1c-1.105 0-2-.895-2-2v-1.09c2.19-.368 3.976-1.92 4.676-3.978C20.11 12.598 22 10.525 22 8V5.062h-4zM4 8v-.938h2v3.766C4.836 10.416 4 9.304 4 8zm16 0c0 1.304-.836 2.416-2 2.83V7.06h2V8z"})));break;case"gridicons-types":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M22 17c0 2.76-2.24 5-5 5s-5-2.24-5-5 2.24-5 5-5 5 2.24 5 5zM6.5 6.5h3.8L7 1 1 11h5.5V6.5zm9.5 4.085V8H8v8h2.585c.433-2.783 2.632-4.982 5.415-5.415z"})));break;case"gridicons-underline":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M4 19v2h16v-2H4zM18 3v8c0 3.314-2.686 6-6 6s-6-2.686-6-6V3h3v8c0 1.654 1.346 3 3 3s3-1.346 3-3V3h3z"})));break;case"gridicons-undo":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M18.142 5.93C16.97 4.756 15.435 4.17 13.9 4.17s-3.072.586-4.244 1.757L6 9.585V6H4v7h7v-2H7.414l3.657-3.657c.756-.755 1.76-1.172 2.83-1.172 1.067 0 2.072.417 2.827 1.173 1.56 1.56 1.56 4.097 0 5.657l-5.364 5.364 1.414 1.414 5.364-5.364c2.345-2.343 2.345-6.142.002-8.485z"})));break;case"gridicons-user-add":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("circle",{cx:"15",cy:"8",r:"4"}),i.default.createElement("path",{d:"M15 20s8 0 8-2c0-2.4-3.9-5-8-5s-8 2.6-8 5c0 2 8 2 8 2zM6 10V7H4v3H1v2h3v3h2v-3h3v-2z"})));break;case"gridicons-user-circle":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm0 18.5c-4.694 0-8.5-3.806-8.5-8.5S7.306 3.5 12 3.5s8.5 3.806 8.5 8.5-3.806 8.5-8.5 8.5zm0-8c-3.038 0-5.5 1.728-5.5 3.5s2.462 3.5 5.5 3.5 5.5-1.728 5.5-3.5-2.462-3.5-5.5-3.5zm0-.5c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3z"})));break;case"gridicons-user":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 4c2.21 0 4 1.79 4 4s-1.79 4-4 4-4-1.79-4-4 1.79-4 4-4zm0 16s8 0 8-2c0-2.4-3.9-5-8-5s-8 2.6-8 5c0 2 8 2 8 2z"})));break;case"gridicons-video-camera":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M17 9V7c0-1.105-.895-2-2-2H4c-1.105 0-2 .895-2 2v10c0 1.105.895 2 2 2h11c1.105 0 2-.895 2-2v-2l5 4V5l-5 4z"})));break;case"gridicons-video-remove":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M19.42 4.59l1.167-1.167L22 4.837 20 6.84V18c0 1.105-.895 2-2 2v-2h-2v2H6.84l-2.007 2.006-1.414-1.414 1.17-1.172-.01-.01L8 16 18 6l1.41-1.42.01.01zM15.84 11H18V8.84L15.84 11zM16 8.01l.01-.01H16v.01zM6 15.17l-2 2V6c0-1.105.895-2 2-2v2h2V4h9.17l-9 9H6v2.17zM6 8v3h2V8H6zm12 8v-3h-2v3h2z"})));break;case"gridicons-video":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M8 4h8v1.997h2V4c1.105 0 2 .896 2 2v12c0 1.104-.895 2-2 2v-2.003h-2V20H8v-2.003H6V20c-1.105 0-2-.895-2-2V6c0-1.105.895-2 2-2v1.997h2V4zm2 11l4.5-3L10 9v6zm8 .997v-3h-2v3h2zm0-5v-3h-2v3h2zm-10 5v-3H6v3h2zm0-5v-3H6v3h2z"})));break;case"gridicons-visible":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M12 6C5.188 6 1 12 1 12s4.188 6 11 6 11-6 11-6-4.188-6-11-6zm0 10c-3.943 0-6.926-2.484-8.38-4 1.04-1.085 2.863-2.657 5.255-3.47C8.335 9.214 8 10.064 8 11c0 2.21 1.79 4 4 4s4-1.79 4-4c0-.937-.335-1.787-.875-2.47 2.393.813 4.216 2.386 5.254 3.47-1.456 1.518-4.438 4-8.38 4z"})));break;case"gridicons-zoom-in":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M15.8 13.8c.7-1.1 1.2-2.4 1.2-3.8 0-3.9-3.1-7-7-7s-7 3.1-7 7 3.1 7 7 7c1.4 0 2.7-.4 3.8-1.2L19 21l2-2-5.2-5.2zM10 15c-2.8 0-5-2.2-5-5s2.2-5 5-5 5 2.2 5 5-2.2 5-5 5z"}),i.default.createElement("path",{d:"M11 7H9v2H7v2h2v2h2v-2h2V9h-2"})));break;case"gridicons-zoom-out":u=i.default.createElement("svg",r({className:l,height:t,width:t,onClick:n},s,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),i.default.createElement("g",null,i.default.createElement("path",{d:"M3 10c0 3.9 3.1 7 7 7 1.4 0 2.7-.5 3.8-1.2L19 21l2-2-5.2-5.2c.8-1.1 1.2-2.4 1.2-3.8 0-3.9-3.1-7-7-7s-7 3.1-7 7zm2 0c0-2.8 2.2-5 5-5s5 2.2 5 5-2.2 5-5 5-5-2.2-5-5z"}),i.default.createElement("path",{d:"M7 9h6v2H7z"})))}return u}}]),t}();u.defaultProps={size:24},u.propTypes={icon:s.default.string.isRequired,size:s.default.number,onClick:s.default.func,className:s.default.string},t.default=u,e.exports=t.default},function(e,t,n){var r=n(659);e.exports=function(e,t){if(null==e)return{};var n,a,o=r(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)n=i[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}},function(e,t){var n=e.exports=window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.DISPLAY_FORMAT="L",t.ISO_FORMAT="YYYY-MM-DD",t.ISO_MONTH_FORMAT="YYYY-MM",t.START_DATE="startDate",t.END_DATE="endDate",t.HORIZONTAL_ORIENTATION="horizontal",t.VERTICAL_ORIENTATION="vertical",t.VERTICAL_SCROLLABLE="verticalScrollable",t.ICON_BEFORE_POSITION="before",t.ICON_AFTER_POSITION="after",t.INFO_POSITION_TOP="top",t.INFO_POSITION_BOTTOM="bottom",t.INFO_POSITION_BEFORE="before",t.INFO_POSITION_AFTER="after",t.ANCHOR_LEFT="left",t.ANCHOR_RIGHT="right",t.OPEN_DOWN="down",t.OPEN_UP="up",t.DAY_SIZE=39,t.BLOCKED_MODIFIER="blocked",t.WEEKDAYS=[0,1,2,3,4,5,6],t.FANG_WIDTH_PX=20,t.FANG_HEIGHT_PX=10,t.DEFAULT_VERTICAL_SPACING=22,t.MODIFIER_KEY_NAMES=new Set(["Shift","Control","Alt","Meta"])},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,n){var r=n(21);e.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},function(e,t){e.exports=function(e){try{return!!e()}catch(t){return!0}}},function(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}(),e.exports=n(618)},function(e,t,n){(function(r){function a(){var e;try{e=t.storage.debug}catch(n){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}(t=e.exports=n(634)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),!n)return;var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var a=0,o=0;e[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(a++,"%c"===e&&(o=a))}),e.splice(o,0,r)},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(n){}},t.load=a,t.useColors=function(){if(window.process&&"renderer"===window.process.type)return!0;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}},t.enable(a())}).call(this,n(126))},function(e,t,n){var r=n(112)("wks"),a=n(68),o=n(19).Symbol,i="function"==typeof o;(e.exports=function(e){return r[e]||(r[e]=i&&o[e]||(i?o:a)("Symbol."+e))}).store=r},function(e,t,n){var r=n(22),a=n(333),o=n(49),i=Object.defineProperty;t.f=n(28)?Object.defineProperty:function(e,t,n){if(r(e),t=o(t,!0),r(n),a)try{return i(e,t,n)}catch(s){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){e.exports=!n(23)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t,n){var r=n(55),a=Math.min;e.exports=function(e){return e>0?a(r(e),9007199254740991):0}},function(e,t,n){e.exports=n(774)},function(e,t,n){var r=n(54);e.exports=function(e){return Object(r(e))}},function(e,t,n){"use strict";var r=n(388);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=(0,i.getCurrencyDefaults)(t);if(!r||isNaN(e))return null;var s=(0,a.default)({},r,n),c=s.decimal,u=s.grouping,l=s.precision,d=s.symbol,f=e<0?"-":"",p=(0,o.numberFormat)(Math.abs(e),{decimals:l,thousandsSep:u,decPoint:c});return"".concat(f).concat(d).concat(p)},t.getCurrencyObject=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=(0,i.getCurrencyDefaults)(t);if(!r||isNaN(e))return null;var s=(0,a.default)({},r,n),c=s.decimal,u=s.grouping,l=s.precision,d=s.symbol,f=e<0?"-":"",p=Math.abs(e),h=Math.floor(p),m=(0,o.numberFormat)(h,{decimals:0,thousandsSep:u,decPoint:c}),v=l>0?(0,o.numberFormat)(p-h,{decimals:l,thousandsSep:u,decPoint:c}).slice(1):"";return{sign:f,symbol:d,integer:m,fraction:v}},Object.defineProperty(t,"getCurrencyDefaults",{enumerable:!0,get:function(){return i.getCurrencyDefaults}}),Object.defineProperty(t,"CURRENCIES",{enumerable:!0,get:function(){return i.CURRENCIES}});var a=r(n(4)),o=n(5),i=n(735)},function(e,t,n){"use strict";var r=n(59),a=n(406),o=n(407),i=n(770),s=o();r(s,{getPolyfill:o,implementation:a,shim:i}),e.exports=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r="Interact with the calendar and add the check-in date for your trip.",a="Move backward to switch to the previous month.",o="Move forward to switch to the next month.",i="page up and page down keys",s="Home and end keys",c="Escape key",u="Select the date in focus.",l="Move backward (left) and forward (right) by one day.",d="Move backward (up) and forward (down) by one week.",f="Return to the date input field.",p="Press the down arrow key to interact with the calendar and\n select a date. Press the question mark key to get the keyboard shortcuts for changing dates.",h=function(e){var t=e.date;return"Choose "+String(t)+" as your check-in date. It’s available."},m=function(e){var t=e.date;return"Choose "+String(t)+" as your check-out date. It’s available."},v=function(e){return e.date},b=function(e){var t=e.date;return"Not available. "+String(t)},g=function(e){var t=e.date;return"Selected. "+String(t)};t.default={calendarLabel:"Calendar",closeDatePicker:"Close",focusStartDate:r,clearDate:"Clear Date",clearDates:"Clear Dates",jumpToPrevMonth:a,jumpToNextMonth:o,keyboardShortcuts:"Keyboard Shortcuts",showKeyboardShortcutsPanel:"Open the keyboard shortcuts panel.",hideKeyboardShortcutsPanel:"Close the shortcuts panel.",openThisPanel:"Open this panel.",enterKey:"Enter key",leftArrowRightArrow:"Right and left arrow keys",upArrowDownArrow:"up and down arrow keys",pageUpPageDown:i,homeEnd:s,escape:c,questionMark:"Question mark",selectFocusedDate:u,moveFocusByOneDay:l,moveFocusByOneWeek:d,moveFocusByOneMonth:"Switch months.",moveFocustoStartAndEndOfWeek:"Go to the first or last day of a week.",returnFocusToInput:f,keyboardNavigationInstructions:p,chooseAvailableStartDate:h,chooseAvailableEndDate:m,dateIsUnavailable:b,dateIsSelected:g};t.DateRangePickerPhrases={calendarLabel:"Calendar",closeDatePicker:"Close",clearDates:"Clear Dates",focusStartDate:r,jumpToPrevMonth:a,jumpToNextMonth:o,keyboardShortcuts:"Keyboard Shortcuts",showKeyboardShortcutsPanel:"Open the keyboard shortcuts panel.",hideKeyboardShortcutsPanel:"Close the shortcuts panel.",openThisPanel:"Open this panel.",enterKey:"Enter key",leftArrowRightArrow:"Right and left arrow keys",upArrowDownArrow:"up and down arrow keys",pageUpPageDown:i,homeEnd:s,escape:c,questionMark:"Question mark",selectFocusedDate:u,moveFocusByOneDay:l,moveFocusByOneWeek:d,moveFocusByOneMonth:"Switch months.",moveFocustoStartAndEndOfWeek:"Go to the first or last day of a week.",returnFocusToInput:f,keyboardNavigationInstructions:p,chooseAvailableStartDate:h,chooseAvailableEndDate:m,dateIsUnavailable:b,dateIsSelected:g},t.DateRangePickerInputPhrases={focusStartDate:r,clearDates:"Clear Dates",keyboardNavigationInstructions:p},t.SingleDatePickerPhrases={calendarLabel:"Calendar",closeDatePicker:"Close",clearDate:"Clear Date",jumpToPrevMonth:a,jumpToNextMonth:o,keyboardShortcuts:"Keyboard Shortcuts",showKeyboardShortcutsPanel:"Open the keyboard shortcuts panel.",hideKeyboardShortcutsPanel:"Close the shortcuts panel.",openThisPanel:"Open this panel.",enterKey:"Enter key",leftArrowRightArrow:"Right and left arrow keys",upArrowDownArrow:"up and down arrow keys",pageUpPageDown:i,homeEnd:s,escape:c,questionMark:"Question mark",selectFocusedDate:u,moveFocusByOneDay:l,moveFocusByOneWeek:d,moveFocusByOneMonth:"Switch months.",moveFocustoStartAndEndOfWeek:"Go to the first or last day of a week.",returnFocusToInput:f,keyboardNavigationInstructions:p,chooseAvailableDate:v,dateIsUnavailable:b,dateIsSelected:g},t.SingleDatePickerInputPhrases={clearDate:"Clear Date",keyboardNavigationInstructions:p},t.DayPickerPhrases={calendarLabel:"Calendar",jumpToPrevMonth:a,jumpToNextMonth:o,keyboardShortcuts:"Keyboard Shortcuts",showKeyboardShortcutsPanel:"Open the keyboard shortcuts panel.",hideKeyboardShortcutsPanel:"Close the shortcuts panel.",openThisPanel:"Open this panel.",enterKey:"Enter key",leftArrowRightArrow:"Right and left arrow keys",upArrowDownArrow:"up and down arrow keys",pageUpPageDown:i,homeEnd:s,escape:c,questionMark:"Question mark",selectFocusedDate:u,moveFocusByOneDay:l,moveFocusByOneWeek:d,moveFocusByOneMonth:"Switch months.",moveFocustoStartAndEndOfWeek:"Go to the first or last day of a week.",returnFocusToInput:f,chooseAvailableStartDate:h,chooseAvailableEndDate:m,chooseAvailableDate:v,dateIsUnavailable:b,dateIsSelected:g},t.DayPickerKeyboardShortcutsPhrases={keyboardShortcuts:"Keyboard Shortcuts",showKeyboardShortcutsPanel:"Open the keyboard shortcuts panel.",hideKeyboardShortcutsPanel:"Close the shortcuts panel.",openThisPanel:"Open this panel.",enterKey:"Enter key",leftArrowRightArrow:"Right and left arrow keys",upArrowDownArrow:"up and down arrow keys",pageUpPageDown:i,homeEnd:s,escape:c,questionMark:"Question mark",selectFocusedDate:u,moveFocusByOneDay:l,moveFocusByOneWeek:d,moveFocusByOneMonth:"Switch months.",moveFocustoStartAndEndOfWeek:"Go to the first or last day of a week.",returnFocusToInput:f},t.DayPickerNavigationPhrases={jumpToPrevMonth:a,jumpToNextMonth:o},t.CalendarDayPhrases={chooseAvailableDate:v,dateIsUnavailable:b,dateIsSelected:g}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return Object.keys(e).reduce(function(e,t){return(0,r.default)({},e,function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}({},t,a.default.oneOfType([a.default.string,a.default.func,a.default.node])))},{})};var r=o(n(33)),a=o(n(2));function o(e){return e&&e.__esModule?e:{default:e}}},function(e,t,n){"use strict";(function(e){n.d(t,"e",function(){return c}),n.d(t,"c",function(){return u}),n.d(t,"d",function(){return l}),n.d(t,"b",function(){return d});var r,a,o=n(5),i=n(1),s=n(445),c=function(e){return r=e},u=function(){return r},l=function(e){return a=e},d=function(){return a},f=function(t,n,i){var c=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"",u={method:i,credentials:"same-origin",headers:{"X-WP-Nonce":r,"Content-Type":"application/json"}};return n&&(u.body=JSON.stringify(n)),c&&!c.endsWith("/")&&(c+="/"),-1!==a.indexOf("?")&&(t=t.replace("?","&")),e(a+c+t,u).then(function(e){return Object(s.a)(e).then(function(e){if(e.success)return e;if("rest_cookie_invalid_nonce"===e.code)return window.persistState=!0,alert(Object(o.translate)("There was a problem saving your settings. Please try again after the page is reloaded.")),void location.reload();throw e})})},p=function(e,t){t&&(Object(i.startsWith)(t,"?")&&(t=t.substring(1)),Object(i.startsWith)(t,"&")||(t="&"+t));var n=Object(i.endsWith)(a,"index.php?rest_route=/")?"&":"?";return"".concat(a).concat(e).concat(n,"_wpnonce=").concat(r).concat(t)};t.a=function(){return{post:function(e,t,n){return f(e,t,"POST",n)},get:function(e,t){return f(e,null,"GET",t)},createGetUrlWithNonce:p}}}).call(this,n(718))},function(e,t,n){var r=n(19),a=n(41),o=n(42),i=n(68)("src"),s=n(459),c=(""+s).split("toString");n(63).inspectSource=function(e){return s.call(e)},(e.exports=function(e,t,n,s){var u="function"==typeof n;u&&(o(n,"name")||a(n,"name",t)),e[t]!==n&&(u&&(o(n,i)||a(n,i,e[t]?""+e[t]:c.join(String(t)))),e===r?e[t]=n:s?e[t]?e[t]=n:a(e,t,n):(delete e[t],a(e,t,n)))})(Function.prototype,"toString",function(){return"function"==typeof this&&this[i]||s.call(this)})},function(e,t,n){var r=n(14),a=n(23),o=n(54),i=/"/g,s=function(e,t,n,r){var a=String(o(e)),s="<"+t;return""!==n&&(s+=" "+n+'="'+String(r).replace(i,"&quot;")+'"'),s+">"+a+"</"+t+">"};e.exports=function(e,t){var n={};n[e]=t(s),r(r.P+r.F*a(function(){var t=""[e]('"');return t!==t.toLowerCase()||t.split('"').length>3}),"String",n)}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.withStylesPropTypes=t.css=void 0;var 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},a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();t.withStyles=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.stylesPropName,i=void 0===n?"styles":n,l=t.themePropName,f=void 0===l?"theme":l,h=t.cssPropName,g=void 0===h?"css":h,y=t.flushBefore,_=void 0!==y&&y,M=t.pureComponent,E=void 0!==M&&M,O=void 0,w=void 0,k=void 0,L=void 0,S=function(e){if(e){if(!o.default.PureComponent)throw new ReferenceError("withStyles() pureComponent option requires React 15.3.0 or later");return o.default.PureComponent}return o.default.Component}(E);function A(e){return e===u.DIRECTIONS.LTR?d.default.resolveLTR:d.default.resolveRTL}function T(t,n){var r=function(e){return e===u.DIRECTIONS.LTR?k:L}(t),a=t===u.DIRECTIONS.LTR?O:w,o=d.default.get();if(a&&r===o)return a;var i=t===u.DIRECTIONS.RTL;return i?(w=e?d.default.createRTL(e):m,L=o,a=w):(O=e?d.default.createLTR(e):m,k=o,a=O),a}function z(e,t){return{resolveMethod:A(e),styleDef:T(e,t)}}return function(){return function(e){var t=e.displayName||e.name||"Component",n=function(n){function s(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(s.__proto__||Object.getPrototypeOf(s)).call(this,e,n)),a=r.context[u.CHANNEL]?r.context[u.CHANNEL].getState():b;return r.state=z(a,t),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(s,n),a(s,[{key:"componentDidMount",value:function(){return function(){var e=this;this.context[u.CHANNEL]&&(this.channelUnsubscribe=this.context[u.CHANNEL].subscribe(function(n){e.setState(z(n,t))}))}}()},{key:"componentWillUnmount",value:function(){return function(){this.channelUnsubscribe&&this.channelUnsubscribe()}}()},{key:"render",value:function(){return function(){var t;_&&d.default.flush();var n=this.state,a=n.resolveMethod,s=n.styleDef;return o.default.createElement(e,r({},this.props,(p(t={},f,d.default.get()),p(t,i,s()),p(t,g,a),t)))}}()}]),s}(S);n.WrappedComponent=e,n.displayName="withStyles("+String(t)+")",n.contextTypes=v,e.propTypes&&(n.propTypes=(0,c.default)({},e.propTypes),delete n.propTypes[i],delete n.propTypes[f],delete n.propTypes[g]);e.defaultProps&&(n.defaultProps=(0,c.default)({},e.defaultProps));return(0,s.default)(n,e)}}()};var o=f(n(0)),i=f(n(2)),s=f(n(264)),c=f(n(775)),u=n(776),l=f(n(777)),d=f(n(404));function f(e){return e&&e.__esModule?e:{default:e}}function p(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}t.css=d.default.resolveLTR,t.withStylesPropTypes={styles:i.default.object.isRequired,theme:i.default.object.isRequired,css:i.default.func.isRequired};var h={},m=function(){return h};var v=p({},u.CHANNEL,l.default),b=u.DIRECTIONS.LTR},function(e,t,n){var r=n(367),a=n(660),o=n(368);e.exports=function(e,t){return r(e)||a(e,t)||o()}},function(e,t,n){var r=n(27),a=n(67);e.exports=n(28)?function(e,t,n){return r.f(e,t,a(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t,n){var r=n(95),a=n(67),o=n(48),i=n(49),s=n(42),c=n(333),u=Object.getOwnPropertyDescriptor;t.f=n(28)?u:function(e,t){if(e=o(e),t=i(t,!0),c)try{return u(e,t)}catch(n){}if(s(e,t))return a(!r.f.call(e,t),e[t])}},function(e,t){e.exports=jQuery},function(e,t,n){"use strict";var r=n(714),a=n(715),o=Array.isArray;e.exports=function(e,t){if(e&&t){if(e.constructor===Object&&t.constructor===Object)return r(e,t);if(o(e)&&o(t))return a(e,t)}return e===t},e.exports.isShallowEqualObjects=r,e.exports.isShallowEqualArrays=a},function(e,t,n){"use strict";var r=n(733),a=n(734),o=n(387);e.exports={formats:o,parse:a,stringify:r}},function(e,t,n){var r=n(113),a=n(54);e.exports=function(e){return r(a(e))}},function(e,t,n){var r=n(21);e.exports=function(e,t){if(!r(e))return e;var n,a;if(t&&"function"==typeof(n=e.toString)&&!r(a=n.call(e)))return a;if("function"==typeof(n=e.valueOf)&&!r(a=n.call(e)))return a;if(!t&&"function"==typeof(n=e.toString)&&!r(a=n.call(e)))return a;throw TypeError("Can't convert object to primitive value")}},function(e,t,n){var r=n(43);e.exports=function(e,t,n){if(r(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,a){return e.call(t,n,r,a)}}return function(){return e.apply(t,arguments)}}},function(e,t,n){var r=n(50),a=n(113),o=n(31),i=n(29),s=n(335);e.exports=function(e,t){var n=1==e,c=2==e,u=3==e,l=4==e,d=6==e,f=5==e||d,p=t||s;return function(t,s,h){for(var m,v,b=o(t),g=a(b),y=r(s,h,3),_=i(g.length),M=0,E=n?p(t,_):c?p(t,0):void 0;_>M;M++)if((f||M in g)&&(v=y(m=g[M],M,b),e))if(n)E[M]=v;else if(v)switch(e){case 3:return!0;case 5:return m;case 6:return M;case 2:E.push(m)}else if(l)return!1;return d?-1:u||l?l:E}}},function(e,t,n){"use strict";var r=n(23);e.exports=function(e,t){return!!e&&r(function(){t?e.call(null,function(){},1):e.call(null)})}},function(e,t,n){var r=n(14),a=n(63),o=n(23);e.exports=function(e,t){var n=(a.Object||{})[e]||Object[e],i={};i[e]=t(n),r(r.S+r.F*o(function(){n(1)}),"Object",i)}},function(e,t){e.exports=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e}},function(e,t){var n=Math.ceil,r=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?r:n)(e)}},function(e,t,n){var r=n(42),a=n(31),o=n(284)("IE_PROTO"),i=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=a(e),r(e,o)?e[o]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?i:null}},function(e,t,n){"use strict";if(n(28)){var r=n(64),a=n(19),o=n(23),i=n(14),s=n(125),c=n(298),u=n(50),l=n(86),d=n(67),f=n(41),p=n(85),h=n(55),m=n(29),v=n(359),b=n(81),g=n(49),y=n(42),_=n(94),M=n(21),E=n(31),O=n(279),w=n(71),k=n(56),L=n(74).f,S=n(281),A=n(68),T=n(26),z=n(51),C=n(116),D=n(96),N=n(282),P=n(82),x=n(115),I=n(84),R=n(278),j=n(334),H=n(27),W=n(44),Y=H.f,q=W.f,B=a.RangeError,F=a.TypeError,V=a.Uint8Array,X=Array.prototype,U=c.ArrayBuffer,G=c.DataView,K=z(0),J=z(2),$=z(3),Q=z(4),Z=z(5),ee=z(6),te=C(!0),ne=C(!1),re=N.values,ae=N.keys,oe=N.entries,ie=X.lastIndexOf,se=X.reduce,ce=X.reduceRight,ue=X.join,le=X.sort,de=X.slice,fe=X.toString,pe=X.toLocaleString,he=T("iterator"),me=T("toStringTag"),ve=A("typed_constructor"),be=A("def_constructor"),ge=s.CONSTR,ye=s.TYPED,_e=s.VIEW,Me=z(1,function(e,t){return Le(D(e,e[be]),t)}),Ee=o(function(){return 1===new V(new Uint16Array([1]).buffer)[0]}),Oe=!!V&&!!V.prototype.set&&o(function(){new V(1).set({})}),we=function(e,t){var n=h(e);if(n<0||n%t)throw B("Wrong offset!");return n},ke=function(e){if(M(e)&&ye in e)return e;throw F(e+" is not a typed array!")},Le=function(e,t){if(!(M(e)&&ve in e))throw F("It is not a typed array constructor!");return new e(t)},Se=function(e,t){return Ae(D(e,e[be]),t)},Ae=function(e,t){for(var n=0,r=t.length,a=Le(e,r);r>n;)a[n]=t[n++];return a},Te=function(e,t,n){Y(e,t,{get:function(){return this._d[n]}})},ze=function(e){var t,n,r,a,o,i,s=E(e),c=arguments.length,l=c>1?arguments[1]:void 0,d=void 0!==l,f=S(s);if(null!=f&&!O(f)){for(i=f.call(s),r=[],t=0;!(o=i.next()).done;t++)r.push(o.value);s=r}for(d&&c>2&&(l=u(l,arguments[2],2)),t=0,n=m(s.length),a=Le(this,n);n>t;t++)a[t]=d?l(s[t],t):s[t];return a},Ce=function(){for(var e=0,t=arguments.length,n=Le(this,t);t>e;)n[e]=arguments[e++];return n},De=!!V&&o(function(){pe.call(new V(1))}),Ne=function(){return pe.apply(De?de.call(ke(this)):ke(this),arguments)},Pe={copyWithin:function(e,t){return j.call(ke(this),e,t,arguments.length>2?arguments[2]:void 0)},every:function(e){return Q(ke(this),e,arguments.length>1?arguments[1]:void 0)},fill:function(e){return R.apply(ke(this),arguments)},filter:function(e){return Se(this,J(ke(this),e,arguments.length>1?arguments[1]:void 0))},find:function(e){return Z(ke(this),e,arguments.length>1?arguments[1]:void 0)},findIndex:function(e){return ee(ke(this),e,arguments.length>1?arguments[1]:void 0)},forEach:function(e){K(ke(this),e,arguments.length>1?arguments[1]:void 0)},indexOf:function(e){return ne(ke(this),e,arguments.length>1?arguments[1]:void 0)},includes:function(e){return te(ke(this),e,arguments.length>1?arguments[1]:void 0)},join:function(e){return ue.apply(ke(this),arguments)},lastIndexOf:function(e){return ie.apply(ke(this),arguments)},map:function(e){return Me(ke(this),e,arguments.length>1?arguments[1]:void 0)},reduce:function(e){return se.apply(ke(this),arguments)},reduceRight:function(e){return ce.apply(ke(this),arguments)},reverse:function(){for(var e,t=ke(this).length,n=Math.floor(t/2),r=0;r<n;)e=this[r],this[r++]=this[--t],this[t]=e;return this},some:function(e){return $(ke(this),e,arguments.length>1?arguments[1]:void 0)},sort:function(e){return le.call(ke(this),e)},subarray:function(e,t){var n=ke(this),r=n.length,a=b(e,r);return new(D(n,n[be]))(n.buffer,n.byteOffset+a*n.BYTES_PER_ELEMENT,m((void 0===t?r:b(t,r))-a))}},xe=function(e,t){return Se(this,de.call(ke(this),e,t))},Ie=function(e){ke(this);var t=we(arguments[1],1),n=this.length,r=E(e),a=m(r.length),o=0;if(a+t>n)throw B("Wrong length!");for(;o<a;)this[t+o]=r[o++]},Re={entries:function(){return oe.call(ke(this))},keys:function(){return ae.call(ke(this))},values:function(){return re.call(ke(this))}},je=function(e,t){return M(e)&&e[ye]&&"symbol"!=typeof t&&t in e&&String(+t)==String(t)},He=function(e,t){return je(e,t=g(t,!0))?d(2,e[t]):q(e,t)},We=function(e,t,n){return!(je(e,t=g(t,!0))&&M(n)&&y(n,"value"))||y(n,"get")||y(n,"set")||n.configurable||y(n,"writable")&&!n.writable||y(n,"enumerable")&&!n.enumerable?Y(e,t,n):(e[t]=n.value,e)};ge||(W.f=He,H.f=We),i(i.S+i.F*!ge,"Object",{getOwnPropertyDescriptor:He,defineProperty:We}),o(function(){fe.call({})})&&(fe=pe=function(){return ue.call(this)});var Ye=p({},Pe);p(Ye,Re),f(Ye,he,Re.values),p(Ye,{slice:xe,set:Ie,constructor:function(){},toString:fe,toLocaleString:Ne}),Te(Ye,"buffer","b"),Te(Ye,"byteOffset","o"),Te(Ye,"byteLength","l"),Te(Ye,"length","e"),Y(Ye,me,{get:function(){return this[ye]}}),e.exports=function(e,t,n,c){var u=e+((c=!!c)?"Clamped":"")+"Array",d="get"+e,p="set"+e,h=a[u],b=h||{},g=h&&k(h),y=!h||!s.ABV,E={},O=h&&h.prototype,S=function(e,n){Y(e,n,{get:function(){return function(e,n){var r=e._d;return r.v[d](n*t+r.o,Ee)}(this,n)},set:function(e){return function(e,n,r){var a=e._d;c&&(r=(r=Math.round(r))<0?0:r>255?255:255&r),a.v[p](n*t+a.o,r,Ee)}(this,n,e)},enumerable:!0})};y?(h=n(function(e,n,r,a){l(e,h,u,"_d");var o,i,s,c,d=0,p=0;if(M(n)){if(!(n instanceof U||"ArrayBuffer"==(c=_(n))||"SharedArrayBuffer"==c))return ye in n?Ae(h,n):ze.call(h,n);o=n,p=we(r,t);var b=n.byteLength;if(void 0===a){if(b%t)throw B("Wrong length!");if((i=b-p)<0)throw B("Wrong length!")}else if((i=m(a)*t)+p>b)throw B("Wrong length!");s=i/t}else s=v(n),o=new U(i=s*t);for(f(e,"_d",{b:o,o:p,l:i,e:s,v:new G(o)});d<s;)S(e,d++)}),O=h.prototype=w(Ye),f(O,"constructor",h)):o(function(){h(1)})&&o(function(){new h(-1)})&&x(function(e){new h,new h(null),new h(1.5),new h(e)},!0)||(h=n(function(e,n,r,a){var o;return l(e,h,u),M(n)?n instanceof U||"ArrayBuffer"==(o=_(n))||"SharedArrayBuffer"==o?void 0!==a?new b(n,we(r,t),a):void 0!==r?new b(n,we(r,t)):new b(n):ye in n?Ae(h,n):ze.call(h,n):new b(v(n))}),K(g!==Function.prototype?L(b).concat(L(g)):L(b),function(e){e in h||f(h,e,b[e])}),h.prototype=O,r||(O.constructor=h));var A=O[he],T=!!A&&("values"==A.name||null==A.name),z=Re.values;f(h,ve,!0),f(O,ye,u),f(O,_e,!0),f(O,be,h),(c?new h(1)[me]==u:me in O)||Y(O,me,{get:function(){return u}}),E[u]=h,i(i.G+i.W+i.F*(h!=b),E),i(i.S,u,{BYTES_PER_ELEMENT:t}),i(i.S+i.F*o(function(){b.of.call(h,1)}),u,{from:ze,of:Ce}),"BYTES_PER_ELEMENT"in O||f(O,"BYTES_PER_ELEMENT",t),i(i.P,u,Pe),I(u),i(i.P+i.F*Oe,u,{set:Ie}),i(i.P+i.F*!T,u,Re),r||O.toString==fe||(O.toString=fe),i(i.P+i.F*o(function(){new h(1).slice()}),u,{slice:xe}),i(i.P+i.F*(o(function(){return[1,2].toLocaleString()!=new h([1,2]).toLocaleString()})||!o(function(){O.toLocaleString.call([1,2])})),u,{toLocaleString:Ne}),P[u]=T?A:z,r||T||f(O,he,z)}}else e.exports=function(){}},function(e,t,n){var r=n(376)("wks"),a=n(312),o=n(66).Symbol,i="function"==typeof o;(e.exports=function(e){return r[e]||(r[e]=i&&o[e]||(i?o:a)("Symbol."+e))}).store=r},function(e,t,n){"use strict";var r=n(314),a="function"==typeof Symbol&&"symbol"==typeof Symbol("foo"),o=Object.prototype.toString,i=Array.prototype.concat,s=Object.defineProperty,c=s&&function(){var e={};try{for(var t in s(e,"x",{enumerable:!1,value:e}),e)return!1;return e.x===e}catch(n){return!1}}(),u=function(e,t,n,r){var a;t in e&&("function"!=typeof(a=r)||"[object Function]"!==o.call(a)||!r())||(c?s(e,t,{configurable:!0,enumerable:!1,value:n,writable:!0}):e[t]=n)},l=function(e,t){var n=arguments.length>2?arguments[2]:{},o=r(t);a&&(o=i.call(o,Object.getOwnPropertySymbols(t)));for(var s=0;s<o.length;s+=1)u(e,o[s],t[o[s]],n[o[s]])};l.supportsDescriptors=!!c,e.exports=l},function(e,t,n){var r=n(8),a=n(772),o=n(773);e.exports={momentObj:o.createMomentChecker("object",function(e){return"object"==typeof e},function(e){return a.isValidMoment(e)},"Moment"),momentString:o.createMomentChecker("string",function(e){return"string"==typeof e},function(e){return a.isValidMoment(r(e))},"Moment"),momentDurationObj:o.createMomentChecker("object",function(e){return"object"==typeof e},function(e){return r.isDuration(e)},"Duration")}},function(e,t,n){var r=n(661),a=n(662),o=n(665),i=n(666),s=n(667),c=function(e){e=JSON.stringify(e);for(var t=/\[([^\[\]"]+)\]/;t.test(e);)e=e.replace(t,'."+$1+"');return e},u={any:function(){return"true"},null:function(e){return e+" === null"},boolean:function(e){return"typeof "+e+' === "boolean"'},array:function(e){return"Array.isArray("+e+")"},object:function(e){return"typeof "+e+' === "object" && '+e+" && !Array.isArray("+e+")"},number:function(e){return"typeof "+e+' === "number" && isFinite('+e+")"},integer:function(e){return"typeof "+e+' === "number" && (Math.floor('+e+") === "+e+" || "+e+" > 9007199254740992 || "+e+" < -9007199254740992)"},string:function(e){return"typeof "+e+' === "string"'}},l=function(e){for(var t=[],n=0;n<e.length;n++)t.push("object"==typeof e[n]?JSON.stringify(e[n]):e[n]);for(n=1;n<t.length;n++)if(t.indexOf(t[n])!==n)return!1;return!0},d=function(e,t){var n,r=(0|t)!==t?Math.pow(10,t.toString().split(".").pop().length):1;r>1?n=((0|e)!==e?Math.pow(10,e.toString().split(".").pop().length):1)>r||Math.round(r*e)%(r*t):n=e%t;return!n},f=function(e,t,n,p,h){var m=h?i(s,h.formats):s,v={unique:l,formats:m,isMultipleOf:d},b=!!h&&!!h.verbose,g=!(!h||void 0===h.greedy)&&h.greedy,y={},_=function(e){return e+(y[e]=(y[e]||0)+1)},M={},E=function(e){if(M[e])return M[e];var t=_("pattern");return v[t]=new RegExp(e),M[e]=t,t},O=["i","j","k","l","m","n","o","p","q","r","s","t","u","v","x","y","z"],w=function(){var e=O.shift();return O.push(e+e[0]),e},k=function(e,a,i,l,d){var p=a.properties,y=a.type,M=!1;Array.isArray(a.items)&&(p={},a.items.forEach(function(e,t){p[t]=e}),y="array",M=!0);var O=0,S=function(t,n,r){L("errors++"),!0===i&&(L("if (validate.errors === null) validate.errors = []"),b?L("validate.errors.push({field:%s,message:%s,value:%s,type:%s,schemaPath:%s})",c(n||e),JSON.stringify(t),r||e,JSON.stringify(y),JSON.stringify(d)):L("validate.errors.push({field:%s,message:%s})",c(n||e),JSON.stringify(t)))};!0===a.required?(O++,L("if (%s === undefined) {",e),S("is required"),L("} else {")):(O++,L("if (%s !== undefined) {",e));var A=[].concat(y).map(function(t){if(t&&!u.hasOwnProperty(t))throw new Error("Unknown type: "+t);return u[t||"any"](e)}).join(" || ")||"true";if("true"!==A&&(O++,L("if (!(%s)) {",A),S("is the wrong type"),L("} else {")),M)if(!1===a.additionalItems)L("if (%s.length > %d) {",e,a.items.length),S("has additional items"),L("}");else if(a.additionalItems){var T=w();L("for (var %s = %d; %s < %s.length; %s++) {",T,a.items.length,T,e,T),k(e+"["+T+"]",a.additionalItems,i,l,d.concat("additionalItems")),L("}")}if(a.format&&m[a.format]){"string"!==y&&s[a.format]&&L("if (%s) {",u.string(e));var z=_("format");v[z]=m[a.format],"function"==typeof v[z]?L("if (!%s(%s)) {",z,e):L("if (!%s.test(%s)) {",z,e),S("must be "+a.format+" format"),L("}"),"string"!==y&&s[a.format]&&L("}")}if(Array.isArray(a.required)){L("if ((%s)) {","object"!==y?u.object(e):"true"),L("var missing = 0"),a.required.map(function(t){var n=r(e,t);L("if (%s === undefined) {",n),S("is required",n),L("missing++"),L("}")}),L("}"),g||(L("if (missing === 0) {"),O++)}if(a.uniqueItems&&("array"!==y&&L("if (%s) {",u.array(e)),L("if (!(unique(%s))) {",e),S("must be unique"),L("}"),"array"!==y&&L("}")),a.enum){var C=a.enum.some(function(e){return"object"==typeof e})?function(t){return"JSON.stringify("+e+") !== JSON.stringify("+JSON.stringify(t)+")"}:function(t){return e+" !== "+JSON.stringify(t)};L("if (%s) {",a.enum.map(C).join(" && ")||"false"),S("must be an enum value"),L("}")}if(a.dependencies&&("object"!==y&&L("if (%s) {",u.object(e)),Object.keys(a.dependencies).forEach(function(t){var n=a.dependencies[t];"string"==typeof n&&(n=[n]);Array.isArray(n)&&(L("if (%s !== undefined && !(%s)) {",r(e,t),n.map(function(t){return r(e,t)+" !== undefined"}).join(" && ")||"true"),S("dependencies not set"),L("}")),"object"==typeof n&&(L("if (%s !== undefined) {",r(e,t)),k(e,n,i,l,d.concat(["dependencies",t])),L("}"))}),"object"!==y&&L("}")),a.additionalProperties||!1===a.additionalProperties){"object"!==y&&L("if (%s) {",u.object(e));T=w();var D=_("keys"),N=Object.keys(p||{}).map(function(e){return D+"["+T+"] !== "+JSON.stringify(e)}).concat(Object.keys(a.patternProperties||{}).map(function(e){return"!"+E(e)+".test("+D+"["+T+"])"})).join(" && ")||"true";L("var %s = Object.keys(%s)",D,e)("for (var %s = 0; %s < %s.length; %s++) {",T,T,D,T)("if (%s) {",N),!1===a.additionalProperties?(l&&L("delete %s",e+"["+D+"["+T+"]]"),S("has additional properties",null,JSON.stringify(e+".")+" + "+D+"["+T+"]")):k(e+"["+D+"["+T+"]]",a.additionalProperties,i,l,d.concat(["additionalProperties"])),L("}")("}"),"object"!==y&&L("}")}if(a.$ref){var P=function(e,t,n){var r=function(e){return e&&e.id===n?e:"object"==typeof e&&e?Object.keys(e).reduce(function(t,n){return t||r(e[n])},null):null},a=r(e);if(a)return a;n=(n=n.replace(/^#/,"")).replace(/\/$/,"");try{return o.get(e,decodeURI(n))}catch(u){var i,s=n.indexOf("#");if(0!==s)if(-1===s)i=t[n];else{i=t[n.slice(0,s)];var c=n.slice(s).replace(/^#/,"");try{return o.get(i,c)}catch(u){}}else i=t[n];return i||null}}(n,h&&h.schemas||{},a.$ref);if(P){var x=t[a.$ref];x||(t[a.$ref]=function(e){return x(e)},x=f(P,t,n,!1,h));z=_("ref");v[z]=x,L("if (!(%s(%s))) {",z,e),S("referenced schema does not match"),L("}")}}if(a.not){var I=_("prev");L("var %s = errors",I),k(e,a.not,!1,l,d.concat("not")),L("if (%s === errors) {",I),S("negative schema matches"),L("} else {")("errors = %s",I)("}")}if(a.items&&!M){"array"!==y&&L("if (%s) {",u.array(e));T=w();L("for (var %s = 0; %s < %s.length; %s++) {",T,T,e,T),k(e+"["+T+"]",a.items,i,l,d.concat("items")),L("}"),"array"!==y&&L("}")}if(a.patternProperties){"object"!==y&&L("if (%s) {",u.object(e));D=_("keys"),T=w();L("var %s = Object.keys(%s)",D,e)("for (var %s = 0; %s < %s.length; %s++) {",T,T,D,T),Object.keys(a.patternProperties).forEach(function(t){var n=E(t);L("if (%s.test(%s)) {",n,D+"["+T+"]"),k(e+"["+D+"["+T+"]]",a.patternProperties[t],i,l,d.concat(["patternProperties",t])),L("}")}),L("}"),"object"!==y&&L("}")}if(a.pattern){var R=E(a.pattern);"string"!==y&&L("if (%s) {",u.string(e)),L("if (!(%s.test(%s))) {",R,e),S("pattern mismatch"),L("}"),"string"!==y&&L("}")}if(a.allOf&&a.allOf.forEach(function(t,n){k(e,t,i,l,d.concat(["allOf",n]))}),a.anyOf&&a.anyOf.length){I=_("prev");a.anyOf.forEach(function(t,n){0===n?L("var %s = errors",I):L("if (errors !== %s) {",I)("errors = %s",I),k(e,t,!1,!1,d)}),a.anyOf.forEach(function(e,t){t&&L("}")}),L("if (%s !== errors) {",I),S("no schemas match"),L("}")}if(a.oneOf&&a.oneOf.length){I=_("prev");var j=_("passes");L("var %s = errors",I)("var %s = 0",j),a.oneOf.forEach(function(t,n){k(e,t,!1,!1,d),L("if (%s === errors) {",I)("%s++",j)("} else {")("errors = %s",I)("}")}),L("if (%s !== 1) {",j),S("no (or more than one) schemas match"),L("}")}for(void 0!==a.multipleOf&&("number"!==y&&"integer"!==y&&L("if (%s) {",u.number(e)),L("if (!isMultipleOf(%s, %d)) {",e,a.multipleOf),S("has a remainder"),L("}"),"number"!==y&&"integer"!==y&&L("}")),void 0!==a.maxProperties&&("object"!==y&&L("if (%s) {",u.object(e)),L("if (Object.keys(%s).length > %d) {",e,a.maxProperties),S("has more properties than allowed"),L("}"),"object"!==y&&L("}")),void 0!==a.minProperties&&("object"!==y&&L("if (%s) {",u.object(e)),L("if (Object.keys(%s).length < %d) {",e,a.minProperties),S("has less properties than allowed"),L("}"),"object"!==y&&L("}")),void 0!==a.maxItems&&("array"!==y&&L("if (%s) {",u.array(e)),L("if (%s.length > %d) {",e,a.maxItems),S("has more items than allowed"),L("}"),"array"!==y&&L("}")),void 0!==a.minItems&&("array"!==y&&L("if (%s) {",u.array(e)),L("if (%s.length < %d) {",e,a.minItems),S("has less items than allowed"),L("}"),"array"!==y&&L("}")),void 0!==a.maxLength&&("string"!==y&&L("if (%s) {",u.string(e)),L("if (%s.length > %d) {",e,a.maxLength),S("has longer length than allowed"),L("}"),"string"!==y&&L("}")),void 0!==a.minLength&&("string"!==y&&L("if (%s) {",u.string(e)),L("if (%s.length < %d) {",e,a.minLength),S("has less length than allowed"),L("}"),"string"!==y&&L("}")),void 0!==a.minimum&&("number"!==y&&"integer"!==y&&L("if (%s) {",u.number(e)),L("if (%s %s %d) {",e,a.exclusiveMinimum?"<=":"<",a.minimum),S("is less than minimum"),L("}"),"number"!==y&&"integer"!==y&&L("}")),void 0!==a.maximum&&("number"!==y&&"integer"!==y&&L("if (%s) {",u.number(e)),L("if (%s %s %d) {",e,a.exclusiveMaximum?">=":">",a.maximum),S("is more than maximum"),L("}"),"number"!==y&&"integer"!==y&&L("}")),p&&Object.keys(p).forEach(function(t){Array.isArray(y)&&-1!==y.indexOf("null")&&L("if (%s !== null) {",e),k(r(e,t),p[t],i,l,d.concat(M?t:["properties",t])),Array.isArray(y)&&-1!==y.indexOf("null")&&L("}")});O--;)L("}")},L=a("function validate(data) {")("if (data === undefined) data = null")("validate.errors = null")("var errors = 0");return k("data",e,p,h&&h.filter,[]),L("return errors === 0")("}"),(L=L.toFunction(v)).errors=null,Object.defineProperty&&Object.defineProperty(L,"error",{get:function(){return L.errors?L.errors.map(function(e){return e.field+" "+e.message}).join("\n"):""}}),L.toJSON=function(){return e},L};e.exports=function(e,t){return"string"==typeof e&&(e=JSON.parse(e)),f(e,{},e,!0,t)},e.exports.filter=function(t,n){var r=e.exports(t,i(n,{filter:!0}));return function(e){return r(e),e}}},function(e,t,n){"use strict";var r=n(727),a=n(728);function o(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}t.parse=y,t.resolve=function(e,t){return y(e,!1,!0).resolve(t)},t.resolveObject=function(e,t){return e?y(e,!1,!0).resolveObject(t):t},t.format=function(e){a.isString(e)&&(e=y(e));return e instanceof o?e.format():o.prototype.format.call(e)},t.Url=o;var i=/^([a-z0-9.+-]+:)/i,s=/:[0-9]*$/,c=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,u=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),l=["'"].concat(u),d=["%","/","?",";","#"].concat(l),f=["/","?","#"],p=/^[+a-z0-9A-Z_-]{0,63}$/,h=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,m={javascript:!0,"javascript:":!0},v={javascript:!0,"javascript:":!0},b={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},g=n(729);function y(e,t,n){if(e&&a.isObject(e)&&e instanceof o)return e;var r=new o;return r.parse(e,t,n),r}o.prototype.parse=function(e,t,n){if(!a.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var o=e.indexOf("?"),s=-1!==o&&o<e.indexOf("#")?"?":"#",u=e.split(s);u[0]=u[0].replace(/\\/g,"/");var y=e=u.join(s);if(y=y.trim(),!n&&1===e.split("#").length){var _=c.exec(y);if(_)return this.path=y,this.href=y,this.pathname=_[1],_[2]?(this.search=_[2],this.query=t?g.parse(this.search.substr(1)):this.search.substr(1)):t&&(this.search="",this.query={}),this}var M=i.exec(y);if(M){var E=(M=M[0]).toLowerCase();this.protocol=E,y=y.substr(M.length)}if(n||M||y.match(/^\/\/[^@\/]+@[^@\/]+/)){var O="//"===y.substr(0,2);!O||M&&v[M]||(y=y.substr(2),this.slashes=!0)}if(!v[M]&&(O||M&&!b[M])){for(var w,k,L=-1,S=0;S<f.length;S++){-1!==(A=y.indexOf(f[S]))&&(-1===L||A<L)&&(L=A)}-1!==(k=-1===L?y.lastIndexOf("@"):y.lastIndexOf("@",L))&&(w=y.slice(0,k),y=y.slice(k+1),this.auth=decodeURIComponent(w)),L=-1;for(S=0;S<d.length;S++){var A;-1!==(A=y.indexOf(d[S]))&&(-1===L||A<L)&&(L=A)}-1===L&&(L=y.length),this.host=y.slice(0,L),y=y.slice(L),this.parseHost(),this.hostname=this.hostname||"";var T="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!T)for(var z=this.hostname.split(/\./),C=(S=0,z.length);S<C;S++){var D=z[S];if(D&&!D.match(p)){for(var N="",P=0,x=D.length;P<x;P++)D.charCodeAt(P)>127?N+="x":N+=D[P];if(!N.match(p)){var I=z.slice(0,S),R=z.slice(S+1),j=D.match(h);j&&(I.push(j[1]),R.unshift(j[2])),R.length&&(y="/"+R.join(".")+y),this.hostname=I.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),T||(this.hostname=r.toASCII(this.hostname));var H=this.port?":"+this.port:"",W=this.hostname||"";this.host=W+H,this.href+=this.host,T&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==y[0]&&(y="/"+y))}if(!m[E])for(S=0,C=l.length;S<C;S++){var Y=l[S];if(-1!==y.indexOf(Y)){var q=encodeURIComponent(Y);q===Y&&(q=escape(Y)),y=y.split(Y).join(q)}}var B=y.indexOf("#");-1!==B&&(this.hash=y.substr(B),y=y.slice(0,B));var F=y.indexOf("?");if(-1!==F?(this.search=y.substr(F),this.query=y.substr(F+1),t&&(this.query=g.parse(this.query)),y=y.slice(0,F)):t&&(this.search="",this.query={}),y&&(this.pathname=y),b[E]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){H=this.pathname||"";var V=this.search||"";this.path=H+V}return this.href=this.format(),this},o.prototype.format=function(){var e=this.auth||"";e&&(e=(e=encodeURIComponent(e)).replace(/%3A/i,":"),e+="@");var t=this.protocol||"",n=this.pathname||"",r=this.hash||"",o=!1,i="";this.host?o=e+this.host:this.hostname&&(o=e+(-1===this.hostname.indexOf(":")?this.hostname:"["+this.hostname+"]"),this.port&&(o+=":"+this.port)),this.query&&a.isObject(this.query)&&Object.keys(this.query).length&&(i=g.stringify(this.query));var s=this.search||i&&"?"+i||"";return t&&":"!==t.substr(-1)&&(t+=":"),this.slashes||(!t||b[t])&&!1!==o?(o="//"+(o||""),n&&"/"!==n.charAt(0)&&(n="/"+n)):o||(o=""),r&&"#"!==r.charAt(0)&&(r="#"+r),s&&"?"!==s.charAt(0)&&(s="?"+s),t+o+(n=n.replace(/[?#]/g,function(e){return encodeURIComponent(e)}))+(s=s.replace("#","%23"))+r},o.prototype.resolve=function(e){return this.resolveObject(y(e,!1,!0)).format()},o.prototype.resolveObject=function(e){if(a.isString(e)){var t=new o;t.parse(e,!1,!0),e=t}for(var n=new o,r=Object.keys(this),i=0;i<r.length;i++){var s=r[i];n[s]=this[s]}if(n.hash=e.hash,""===e.href)return n.href=n.format(),n;if(e.slashes&&!e.protocol){for(var c=Object.keys(e),u=0;u<c.length;u++){var l=c[u];"protocol"!==l&&(n[l]=e[l])}return b[n.protocol]&&n.hostname&&!n.pathname&&(n.path=n.pathname="/"),n.href=n.format(),n}if(e.protocol&&e.protocol!==n.protocol){if(!b[e.protocol]){for(var d=Object.keys(e),f=0;f<d.length;f++){var p=d[f];n[p]=e[p]}return n.href=n.format(),n}if(n.protocol=e.protocol,e.host||v[e.protocol])n.pathname=e.pathname;else{for(var h=(e.pathname||"").split("/");h.length&&!(e.host=h.shift()););e.host||(e.host=""),e.hostname||(e.hostname=""),""!==h[0]&&h.unshift(""),h.length<2&&h.unshift(""),n.pathname=h.join("/")}if(n.search=e.search,n.query=e.query,n.host=e.host||"",n.auth=e.auth,n.hostname=e.hostname||e.host,n.port=e.port,n.pathname||n.search){var m=n.pathname||"",g=n.search||"";n.path=m+g}return n.slashes=n.slashes||e.slashes,n.href=n.format(),n}var y=n.pathname&&"/"===n.pathname.charAt(0),_=e.host||e.pathname&&"/"===e.pathname.charAt(0),M=_||y||n.host&&e.pathname,E=M,O=n.pathname&&n.pathname.split("/")||[],w=(h=e.pathname&&e.pathname.split("/")||[],n.protocol&&!b[n.protocol]);if(w&&(n.hostname="",n.port=null,n.host&&(""===O[0]?O[0]=n.host:O.unshift(n.host)),n.host="",e.protocol&&(e.hostname=null,e.port=null,e.host&&(""===h[0]?h[0]=e.host:h.unshift(e.host)),e.host=null),M=M&&(""===h[0]||""===O[0])),_)n.host=e.host||""===e.host?e.host:n.host,n.hostname=e.hostname||""===e.hostname?e.hostname:n.hostname,n.search=e.search,n.query=e.query,O=h;else if(h.length)O||(O=[]),O.pop(),O=O.concat(h),n.search=e.search,n.query=e.query;else if(!a.isNullOrUndefined(e.search)){if(w)n.hostname=n.host=O.shift(),(T=!!(n.host&&n.host.indexOf("@")>0)&&n.host.split("@"))&&(n.auth=T.shift(),n.host=n.hostname=T.shift());return n.search=e.search,n.query=e.query,a.isNull(n.pathname)&&a.isNull(n.search)||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.href=n.format(),n}if(!O.length)return n.pathname=null,n.search?n.path="/"+n.search:n.path=null,n.href=n.format(),n;for(var k=O.slice(-1)[0],L=(n.host||e.host||O.length>1)&&("."===k||".."===k)||""===k,S=0,A=O.length;A>=0;A--)"."===(k=O[A])?O.splice(A,1):".."===k?(O.splice(A,1),S++):S&&(O.splice(A,1),S--);if(!M&&!E)for(;S--;S)O.unshift("..");!M||""===O[0]||O[0]&&"/"===O[0].charAt(0)||O.unshift(""),L&&"/"!==O.join("/").substr(-1)&&O.push("");var T,z=""===O[0]||O[0]&&"/"===O[0].charAt(0);w&&(n.hostname=n.host=z?"":O.length?O.shift():"",(T=!!(n.host&&n.host.indexOf("@")>0)&&n.host.split("@"))&&(n.auth=T.shift(),n.host=n.hostname=T.shift()));return(M=M||n.host&&O.length)&&!z&&O.unshift(""),O.length?n.pathname=O.join("/"):(n.pathname=null,n.path=null),a.isNull(n.pathname)&&a.isNull(n.search)||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.auth=e.auth||n.auth,n.slashes=n.slashes||e.slashes,n.href=n.format(),n},o.prototype.parseHost=function(){var e=this.host,t=s.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)}},function(e,t){var n=e.exports={version:"2.6.5"};"number"==typeof __e&&(__e=n)},function(e,t){e.exports=!1},function(e,t,n){var r=n(68)("meta"),a=n(21),o=n(42),i=n(27).f,s=0,c=Object.isExtensible||function(){return!0},u=!n(23)(function(){return c(Object.preventExtensions({}))}),l=function(e){i(e,r,{value:{i:"O"+ ++s,w:{}}})},d=e.exports={KEY:r,NEED:!1,fastKey:function(e,t){if(!a(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!o(e,r)){if(!c(e))return"F";if(!t)return"E";l(e)}return e[r].i},getWeak:function(e,t){if(!o(e,r)){if(!c(e))return!0;if(!t)return!1;l(e)}return e[r].w},onFreeze:function(e){return u&&d.NEED&&c(e)&&!o(e,r)&&l(e),e}}},function(e,t){var n=e.exports=window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t){var n=0,r=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++n+r).toString(36))}},function(e,t,n){var r=n(26)("unscopables"),a=Array.prototype;null==a[r]&&n(41)(a,r,{}),e.exports=function(e){a[r][e]=!0}},function(e,t){var n={}.toString;e.exports=function(e){return n.call(e).slice(8,-1)}},function(e,t,n){var r=n(22),a=n(338),o=n(285),i=n(284)("IE_PROTO"),s=function(){},c=function(){var e,t=n(277)("iframe"),r=o.length;for(t.style.display="none",n(340).appendChild(t),t.src="javascript:",(e=t.contentWindow.document).open(),e.write("<script>document.F=Object<\/script>"),e.close(),c=e.F;r--;)delete c.prototype[o[r]];return c()};e.exports=Object.create||function(e,t){var n;return null!==e?(s.prototype=r(e),n=new s,s.prototype=null,n[i]=e):n=c(),void 0===t?n:a(n,t)}},function(e,t,n){var r=n(339),a=n(285);e.exports=Object.keys||function(e){return r(e,a)}},function(e,t,n){var r=n(21);e.exports=function(e,t){if(!r(e)||e._t!==t)throw TypeError("Incompatible receiver, "+t+" required!");return e}},function(e,t,n){var r=n(339),a=n(285).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,a)}},function(e,t,n){var r=n(76),a=n(373);e.exports=n(78)?function(e,t,n){return r.f(e,t,a(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t,n){var r=n(100),a=n(678),o=n(679),i=Object.defineProperty;t.f=n(78)?Object.defineProperty:function(e,t,n){if(r(e),t=o(t,!0),r(n),a)try{return i(e,t,n)}catch(s){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,n){e.exports=!n(254)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t,n){"use strict";var r=n(751);e.exports=Function.prototype.bind||r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,a=n(2),o=(r=a)&&r.__esModule?r:{default:r},i=n(20);t.default=o.default.oneOf(i.WEEKDAYS)},function(e,t,n){var r=n(55),a=Math.max,o=Math.min;e.exports=function(e,t){return(e=r(e))<0?a(e+t,0):o(e,t)}},function(e,t){e.exports={}},function(e,t,n){var r=n(27).f,a=n(42),o=n(26)("toStringTag");e.exports=function(e,t,n){e&&!a(e=n?e:e.prototype,o)&&r(e,o,{configurable:!0,value:t})}},function(e,t,n){"use strict";var r=n(19),a=n(27),o=n(28),i=n(26)("species");e.exports=function(e){var t=r[e];o&&t&&!t[i]&&a.f(t,i,{configurable:!0,get:function(){return this}})}},function(e,t,n){var r=n(37);e.exports=function(e,t,n){for(var a in t)r(e,a,t[a],n);return e}},function(e,t){e.exports=function(e,t,n,r){if(!(e instanceof t)||void 0!==r&&r in e)throw TypeError(n+": incorrect invocation!");return e}},function(e,t,n){var r=n(14),a=n(54),o=n(23),i=n(290),s="["+i+"]",c=RegExp("^"+s+s+"*"),u=RegExp(s+s+"*$"),l=function(e,t,n){var a={},s=o(function(){return!!i[e]()||"​…"!="​…"[e]()}),c=a[e]=s?t(d):i[e];n&&(a[n]=c),r(r.P+r.F*s,"String",a)},d=l.trim=function(e,t){return e=String(a(e)),1&t&&(e=e.replace(c,"")),2&t&&(e=e.replace(u,"")),e};e.exports=l},function(e,t,n){"use strict";var r=n(771);e.exports=function(e,t,n){return!r(e.props,t)||!r(e.state,n)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return!(!o.default.isMoment(e)||!o.default.isMoment(t))&&e.date()===t.date()&&e.month()===t.month()&&e.year()===t.year()};var r,a=n(8),o=(r=a)&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n=t?[t,i.DISPLAY_FORMAT,i.ISO_FORMAT]:[i.DISPLAY_FORMAT,i.ISO_FORMAT],r=(0,o.default)(e,n,!0);return r.isValid()?r.hour(12):null};var r,a=n(8),o=(r=a)&&r.__esModule?r:{default:r},i=n(20)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,a=n(2),o=(r=a)&&r.__esModule?r:{default:r},i=n(20);t.default=o.default.oneOf([i.HORIZONTAL_ORIENTATION,i.VERTICAL_ORIENTATION,i.VERTICAL_SCROLLABLE])},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){return!!("ontouchstart"in window||window.DocumentTouch&&"undefined"!=typeof document&&document instanceof window.DocumentTouch)||!("undefined"==typeof navigator||!navigator.maxTouchPoints&&!navigator.msMaxTouchPoints)},e.exports=t.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,a=n(2),o=(r=a)&&r.__esModule?r:{default:r},i=n(20);t.default=o.default.oneOf([i.OPEN_DOWN,i.OPEN_UP])},function(e,t,n){var r=n(70),a=n(26)("toStringTag"),o="Arguments"==r(function(){return arguments}());e.exports=function(e){var t,n,i;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=function(e,t){try{return e[t]}catch(n){}}(t=Object(e),a))?n:o?r(t):"Object"==(i=r(t))&&"function"==typeof t.callee?"Arguments":i}},function(e,t){t.f={}.propertyIsEnumerable},function(e,t,n){var r=n(22),a=n(43),o=n(26)("species");e.exports=function(e,t){var n,i=r(e).constructor;return void 0===i||null==(n=r(i)[o])?t:a(n)}},function(e,t,n){var r=n(66),a=n(98),o=n(99),i=n(75),s=n(101),c=function(e,t,n){var u,l,d,f=e&c.F,p=e&c.G,h=e&c.S,m=e&c.P,v=e&c.B,b=e&c.W,g=p?a:a[t]||(a[t]={}),y=g.prototype,_=p?r:h?r[t]:(r[t]||{}).prototype;for(u in p&&(n=t),n)(l=!f&&_&&void 0!==_[u])&&s(g,u)||(d=l?_[u]:n[u],g[u]=p&&"function"!=typeof _[u]?n[u]:v&&l?o(d,r):b&&_[u]==d?function(e){var t=function(t,n,r){if(this instanceof e){switch(arguments.length){case 0:return new e;case 1:return new e(t);case 2:return new e(t,n)}return new e(t,n,r)}return e.apply(this,arguments)};return t.prototype=e.prototype,t}(d):m&&"function"==typeof d?o(Function.call,d):d,m&&((g.virtual||(g.virtual={}))[u]=d,e&c.R&&y&&!y[u]&&i(y,u,d)))};c.F=1,c.G=2,c.S=4,c.P=8,c.B=16,c.W=32,c.U=64,c.R=128,e.exports=c},function(e,t){var n=e.exports={version:"2.6.5"};"number"==typeof __e&&(__e=n)},function(e,t,n){var r=n(371);e.exports=function(e,t,n){if(r(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,a){return e.call(t,n,r,a)}}return function(){return e.apply(t,arguments)}}},function(e,t,n){var r=n(77);e.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},function(e,t){e.exports={}},function(e,t,n){"use strict";var r=n(79);e.exports=r.call(Function.call,Object.prototype.hasOwnProperty)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,a=n(2),o=(r=a)&&r.__esModule?r:{default:r},i=n(20);t.default=o.default.oneOf([i.ICON_BEFORE_POSITION,i.ICON_AFTER_POSITION])},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,a=n(2),o=(r=a)&&r.__esModule?r:{default:r},i=n(20);t.default=o.default.oneOf([i.INFO_POSITION_TOP,i.INFO_POSITION_BOTTOM,i.INFO_POSITION_BEFORE,i.INFO_POSITION_AFTER])},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return!(!r.default.isMoment(e)||!r.default.isMoment(t)||(0,a.default)(e,t))};var r=o(n(8)),a=o(n(107));function o(e){return e&&e.__esModule?e:{default:e}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if(!o.default.isMoment(e)||!o.default.isMoment(t))return!1;var n=e.year(),r=e.month(),a=t.year(),i=t.month(),s=n===a,c=r===i;return s&&c?e.date()<t.date():s?r<i:n<a};var r,a=n(8),o=(r=a)&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,a=n(0),o=(r=a)&&r.__esModule?r:{default:r};var i=function(){return function(e){return o.default.createElement("svg",e,o.default.createElement("path",{fillRule:"evenodd",d:"M11.53.47a.75.75 0 0 0-1.061 0l-4.47 4.47L1.529.47A.75.75 0 1 0 .468 1.531l4.47 4.47-4.47 4.47a.75.75 0 1 0 1.061 1.061l4.47-4.47 4.47 4.47a.75.75 0 1 0 1.061-1.061l-4.47-4.47 4.47-4.47a.75.75 0 0 0 0-1.061z"}))}}();i.defaultProps={viewBox:"0 0 12 12"},t.default=i},function(e,t){e.exports=function(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}},function(e,t,n){var r=n(713);e.exports=function(e){var t=null,n=r(e);if(3===e.nodeType){var a=n.createRange();a.selectNodeContents(e),e=a}if("function"==typeof e.getBoundingClientRect&&(t=e.getBoundingClientRect(),e.startContainer&&0===t.left&&0===t.top)){var o=n.createElement("span");o.appendChild(n.createTextNode("​")),e.insertNode(o),t=o.getBoundingClientRect();var i=o.parentNode;i.removeChild(o),i.normalize()}return t}},function(e,t,n){e.exports=n(737)},function(e,t,n){var r=n(63),a=n(19),o=a["__core-js_shared__"]||(a["__core-js_shared__"]={});(e.exports=function(e,t){return o[e]||(o[e]=void 0!==t?t:{})})("versions",[]).push({version:r.version,mode:n(64)?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},function(e,t,n){var r=n(70);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},function(e,t,n){var r=n(70);e.exports=Array.isArray||function(e){return"Array"==r(e)}},function(e,t,n){var r=n(26)("iterator"),a=!1;try{var o=[7][r]();o.return=function(){a=!0},Array.from(o,function(){throw 2})}catch(i){}e.exports=function(e,t){if(!t&&!a)return!1;var n=!1;try{var o=[7],s=o[r]();s.next=function(){return{done:n=!0}},o[r]=function(){return s},e(o)}catch(i){}return n}},function(e,t,n){var r=n(48),a=n(29),o=n(81);e.exports=function(e){return function(t,n,i){var s,c=r(t),u=a(c.length),l=o(i,u);if(e&&n!=n){for(;u>l;)if((s=c[l++])!=s)return!0}else for(;u>l;l++)if((e||l in c)&&c[l]===n)return e||l||0;return!e&&-1}}},function(e,t,n){var r=n(50),a=n(336),o=n(279),i=n(22),s=n(29),c=n(281),u={},l={};(t=e.exports=function(e,t,n,d,f){var p,h,m,v,b=f?function(){return e}:c(e),g=r(n,d,t?2:1),y=0;if("function"!=typeof b)throw TypeError(e+" is not iterable!");if(o(b)){for(p=s(e.length);p>y;y++)if((v=t?g(i(h=e[y])[0],h[1]):g(e[y]))===u||v===l)return v}else for(m=b.call(e);!(h=m.next()).done;)if((v=a(m,g,h.value,t))===u||v===l)return v}).BREAK=u,t.RETURN=l},function(e,t,n){"use strict";var r=n(19),a=n(14),o=n(37),i=n(85),s=n(65),c=n(117),u=n(86),l=n(21),d=n(23),f=n(115),p=n(83),h=n(286);e.exports=function(e,t,n,m,v,b){var g=r[e],y=g,_=v?"set":"add",M=y&&y.prototype,E={},O=function(e){var t=M[e];o(M,e,"delete"==e?function(e){return!(b&&!l(e))&&t.call(this,0===e?0:e)}:"has"==e?function(e){return!(b&&!l(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return b&&!l(e)?void 0:t.call(this,0===e?0:e)}:"add"==e?function(e){return t.call(this,0===e?0:e),this}:function(e,n){return t.call(this,0===e?0:e,n),this})};if("function"==typeof y&&(b||M.forEach&&!d(function(){(new y).entries().next()}))){var w=new y,k=w[_](b?{}:-0,1)!=w,L=d(function(){w.has(1)}),S=f(function(e){new y(e)}),A=!b&&d(function(){for(var e=new y,t=5;t--;)e[_](t,t);return!e.has(-0)});S||((y=t(function(t,n){u(t,y,e);var r=h(new g,t,y);return null!=n&&c(n,v,r[_],r),r})).prototype=M,M.constructor=y),(L||A)&&(O("delete"),O("has"),v&&O("get")),(A||k)&&O(_),b&&M.clear&&delete M.clear}else y=m.getConstructor(t,e,v,_),i(y.prototype,n),s.NEED=!0;return p(y,e),E[e]=y,a(a.G+a.W+a.F*(y!=g),E),b||m.setStrong(y,e,v),y}},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,n){"use strict";e.exports=n(64)||!n(23)(function(){var e=Math.random();__defineSetter__.call(null,e,function(){}),delete n(19)[e]})},function(e,t,n){var r=n(19).navigator;e.exports=r&&r.userAgent||""},function(e,t,n){"use strict";var r=n(22);e.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},function(e,t,n){"use strict";var r=n(94),a=RegExp.prototype.exec;e.exports=function(e,t){var n=e.exec;if("function"==typeof n){var o=n.call(e,t);if("object"!=typeof o)throw new TypeError("RegExp exec method returned something other than an Object or null");return o}if("RegExp"!==r(e))throw new TypeError("RegExp#exec called on incompatible receiver");return a.call(e,t)}},function(e,t,n){"use strict";n(566);var r=n(37),a=n(41),o=n(23),i=n(54),s=n(26),c=n(295),u=s("species"),l=!o(function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")}),d=function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var n="ab".split(e);return 2===n.length&&"a"===n[0]&&"b"===n[1]}();e.exports=function(e,t,n){var f=s(e),p=!o(function(){var t={};return t[f]=function(){return 7},7!=""[e](t)}),h=p?!o(function(){var t=!1,n=/a/;return n.exec=function(){return t=!0,null},"split"===e&&(n.constructor={},n.constructor[u]=function(){return n}),n[f](""),!t}):void 0;if(!p||!h||"replace"===e&&!l||"split"===e&&!d){var m=/./[f],v=n(i,f,""[e],function(e,t,n,r,a){return t.exec===c?p&&!a?{done:!0,value:m.call(t,n,r)}:{done:!0,value:e.call(n,t,r)}:{done:!1}}),b=v[0],g=v[1];r(String.prototype,e,b),a(RegExp.prototype,f,2==t?function(e,t){return g.call(e,this,t)}:function(e){return g.call(e,this)})}}},function(e,t,n){for(var r,a=n(19),o=n(41),i=n(68),s=i("typed_array"),c=i("view"),u=!(!a.ArrayBuffer||!a.DataView),l=u,d=0,f="Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array".split(",");d<9;)(r=a[f[d++]])?(o(r.prototype,s,!0),o(r.prototype,c,!0)):l=!1;e.exports={ABV:u,CONSTR:l,TYPED:s,VIEW:c}},function(e,t){var n,r,a=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function s(e){if(n===setTimeout)return setTimeout(e,0);if((n===o||!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:o}catch(e){n=o}try{r="function"==typeof clearTimeout?clearTimeout:i}catch(e){r=i}}();var c,u=[],l=!1,d=-1;function f(){l&&c&&(l=!1,c.length?u=c.concat(u):d=-1,u.length&&p())}function p(){if(!l){var e=s(f);l=!0;for(var t=u.length;t;){for(c=u,u=[];++d<t;)c&&c[d].run();d=-1,t=u.length}c=null,l=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===i||!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 h(e,t){this.fun=e,this.array=t}function m(){}a.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];u.push(new h(e,t)),1!==u.length||l||s(p)},h.prototype.run=function(){this.fun.apply(null,this.array)},a.title="browser",a.browser=!0,a.env={},a.argv=[],a.version="",a.versions={},a.on=m,a.addListener=m,a.once=m,a.off=m,a.removeListener=m,a.removeAllListeners=m,a.emit=m,a.prependListener=m,a.prependOnceListener=m,a.listeners=function(e){return[]},a.binding=function(e){throw new Error("process.binding is not supported")},a.cwd=function(){return"/"},a.chdir=function(e){throw new Error("process.chdir is not supported")},a.umask=function(){return 0}},function(e,t,n){!function(e){"use strict";e.defineLocale("af",{months:"Januarie_Februarie_Maart_April_Mei_Junie_Julie_Augustus_September_Oktober_November_Desember".split("_"),monthsShort:"Jan_Feb_Mrt_Apr_Mei_Jun_Jul_Aug_Sep_Okt_Nov_Des".split("_"),weekdays:"Sondag_Maandag_Dinsdag_Woensdag_Donderdag_Vrydag_Saterdag".split("_"),weekdaysShort:"Son_Maa_Din_Woe_Don_Vry_Sat".split("_"),weekdaysMin:"So_Ma_Di_Wo_Do_Vr_Sa".split("_"),meridiemParse:/vm|nm/i,isPM:function(e){return/^nm$/i.test(e)},meridiem:function(e,t,n){return e<12?n?"vm":"VM":n?"nm":"NM"},longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Vandag om] LT",nextDay:"[Môre om] LT",nextWeek:"dddd [om] LT",lastDay:"[Gister om] LT",lastWeek:"[Laas] dddd [om] LT",sameElse:"L"},relativeTime:{future:"oor %s",past:"%s gelede",s:"'n paar sekondes",ss:"%d sekondes",m:"'n minuut",mm:"%d minute",h:"'n uur",hh:"%d ure",d:"'n dag",dd:"%d dae",M:"'n maand",MM:"%d maande",y:"'n jaar",yy:"%d jaar"},dayOfMonthOrdinalParse:/\d{1,2}(ste|de)/,ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩",0:"٠"},n={"١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","٠":"0"},r=function(e){return 0===e?0:1===e?1:2===e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5},a={s:["أقل من ثانية","ثانية واحدة",["ثانيتان","ثانيتين"],"%d ثوان","%d ثانية","%d ثانية"],m:["أقل من دقيقة","دقيقة واحدة",["دقيقتان","دقيقتين"],"%d دقائق","%d دقيقة","%d دقيقة"],h:["أقل من ساعة","ساعة واحدة",["ساعتان","ساعتين"],"%d ساعات","%d ساعة","%d ساعة"],d:["أقل من يوم","يوم واحد",["يومان","يومين"],"%d أيام","%d يومًا","%d يوم"],M:["أقل من شهر","شهر واحد",["شهران","شهرين"],"%d أشهر","%d شهرا","%d شهر"],y:["أقل من عام","عام واحد",["عامان","عامين"],"%d أعوام","%d عامًا","%d عام"]},o=function(e){return function(t,n,o,i){var s=r(t),c=a[e][r(t)];return 2===s&&(c=c[n?0:1]),c.replace(/%d/i,t)}},i=["يناير","فبراير","مارس","أبريل","مايو","يونيو","يوليو","أغسطس","سبتمبر","أكتوبر","نوفمبر","ديسمبر"];e.defineLocale("ar",{months:i,monthsShort:i,weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"D/‏M/‏YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},meridiemParse:/ص|م/,isPM:function(e){return"م"===e},meridiem:function(e,t,n){return e<12?"ص":"م"},calendar:{sameDay:"[اليوم عند الساعة] LT",nextDay:"[غدًا عند الساعة] LT",nextWeek:"dddd [عند الساعة] LT",lastDay:"[أمس عند الساعة] LT",lastWeek:"dddd [عند الساعة] LT",sameElse:"L"},relativeTime:{future:"بعد %s",past:"منذ %s",s:o("s"),ss:o("s"),m:o("m"),mm:o("m"),h:o("h"),hh:o("h"),d:o("d"),dd:o("d"),M:o("M"),MM:o("M"),y:o("y"),yy:o("y")},preparse:function(e){return e.replace(/[١٢٣٤٥٦٧٨٩٠]/g,function(e){return n[e]}).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]}).replace(/,/g,"،")},week:{dow:6,doy:12}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ar-dz",{months:"جانفي_فيفري_مارس_أفريل_ماي_جوان_جويلية_أوت_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),monthsShort:"جانفي_فيفري_مارس_أفريل_ماي_جوان_جويلية_أوت_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"احد_اثنين_ثلاثاء_اربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"أح_إث_ثلا_أر_خم_جم_سب".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",ss:"%d ثانية",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},week:{dow:0,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ar-kw",{months:"يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر".split("_"),monthsShort:"يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر".split("_"),weekdays:"الأحد_الإتنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"احد_اتنين_ثلاثاء_اربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",ss:"%d ثانية",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},week:{dow:0,doy:12}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",0:"0"},n=function(e){return 0===e?0:1===e?1:2===e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5},r={s:["أقل من ثانية","ثانية واحدة",["ثانيتان","ثانيتين"],"%d ثوان","%d ثانية","%d ثانية"],m:["أقل من دقيقة","دقيقة واحدة",["دقيقتان","دقيقتين"],"%d دقائق","%d دقيقة","%d دقيقة"],h:["أقل من ساعة","ساعة واحدة",["ساعتان","ساعتين"],"%d ساعات","%d ساعة","%d ساعة"],d:["أقل من يوم","يوم واحد",["يومان","يومين"],"%d أيام","%d يومًا","%d يوم"],M:["أقل من شهر","شهر واحد",["شهران","شهرين"],"%d أشهر","%d شهرا","%d شهر"],y:["أقل من عام","عام واحد",["عامان","عامين"],"%d أعوام","%d عامًا","%d عام"]},a=function(e){return function(t,a,o,i){var s=n(t),c=r[e][n(t)];return 2===s&&(c=c[a?0:1]),c.replace(/%d/i,t)}},o=["يناير","فبراير","مارس","أبريل","مايو","يونيو","يوليو","أغسطس","سبتمبر","أكتوبر","نوفمبر","ديسمبر"];e.defineLocale("ar-ly",{months:o,monthsShort:o,weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"D/‏M/‏YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},meridiemParse:/ص|م/,isPM:function(e){return"م"===e},meridiem:function(e,t,n){return e<12?"ص":"م"},calendar:{sameDay:"[اليوم عند الساعة] LT",nextDay:"[غدًا عند الساعة] LT",nextWeek:"dddd [عند الساعة] LT",lastDay:"[أمس عند الساعة] LT",lastWeek:"dddd [عند الساعة] LT",sameElse:"L"},relativeTime:{future:"بعد %s",past:"منذ %s",s:a("s"),ss:a("s"),m:a("m"),mm:a("m"),h:a("h"),hh:a("h"),d:a("d"),dd:a("d"),M:a("M"),MM:a("M"),y:a("y"),yy:a("y")},preparse:function(e){return e.replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]}).replace(/,/g,"،")},week:{dow:6,doy:12}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ar-ma",{months:"يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر".split("_"),monthsShort:"يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر".split("_"),weekdays:"الأحد_الإتنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"احد_اتنين_ثلاثاء_اربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",ss:"%d ثانية",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},week:{dow:6,doy:12}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩",0:"٠"},n={"١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","٠":"0"};e.defineLocale("ar-sa",{months:"يناير_فبراير_مارس_أبريل_مايو_يونيو_يوليو_أغسطس_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),monthsShort:"يناير_فبراير_مارس_أبريل_مايو_يونيو_يوليو_أغسطس_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},meridiemParse:/ص|م/,isPM:function(e){return"م"===e},meridiem:function(e,t,n){return e<12?"ص":"م"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",ss:"%d ثانية",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},preparse:function(e){return e.replace(/[١٢٣٤٥٦٧٨٩٠]/g,function(e){return n[e]}).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]}).replace(/,/g,"،")},week:{dow:0,doy:6}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ar-tn",{months:"جانفي_فيفري_مارس_أفريل_ماي_جوان_جويلية_أوت_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),monthsShort:"جانفي_فيفري_مارس_أفريل_ماي_جوان_جويلية_أوت_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",ss:"%d ثانية",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"-inci",5:"-inci",8:"-inci",70:"-inci",80:"-inci",2:"-nci",7:"-nci",20:"-nci",50:"-nci",3:"-üncü",4:"-üncü",100:"-üncü",6:"-ncı",9:"-uncu",10:"-uncu",30:"-uncu",60:"-ıncı",90:"-ıncı"};e.defineLocale("az",{months:"yanvar_fevral_mart_aprel_may_iyun_iyul_avqust_sentyabr_oktyabr_noyabr_dekabr".split("_"),monthsShort:"yan_fev_mar_apr_may_iyn_iyl_avq_sen_okt_noy_dek".split("_"),weekdays:"Bazar_Bazar ertəsi_Çərşənbə axşamı_Çərşənbə_Cümə axşamı_Cümə_Şənbə".split("_"),weekdaysShort:"Baz_BzE_ÇAx_Çər_CAx_Cüm_Şən".split("_"),weekdaysMin:"Bz_BE_ÇA_Çə_CA_Cü_Şə".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[bugün saat] LT",nextDay:"[sabah saat] LT",nextWeek:"[gələn həftə] dddd [saat] LT",lastDay:"[dünən] LT",lastWeek:"[keçən həftə] dddd [saat] LT",sameElse:"L"},relativeTime:{future:"%s sonra",past:"%s əvvəl",s:"birneçə saniyə",ss:"%d saniyə",m:"bir dəqiqə",mm:"%d dəqiqə",h:"bir saat",hh:"%d saat",d:"bir gün",dd:"%d gün",M:"bir ay",MM:"%d ay",y:"bir il",yy:"%d il"},meridiemParse:/gecə|səhər|gündüz|axşam/,isPM:function(e){return/^(gündüz|axşam)$/.test(e)},meridiem:function(e,t,n){return e<4?"gecə":e<12?"səhər":e<17?"gündüz":"axşam"},dayOfMonthOrdinalParse:/\d{1,2}-(ıncı|inci|nci|üncü|ncı|uncu)/,ordinal:function(e){if(0===e)return e+"-ıncı";var n=e%10,r=e%100-n,a=e>=100?100:null;return e+(t[n]||t[r]||t[a])},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n){var r,a,o={ss:t?"секунда_секунды_секунд":"секунду_секунды_секунд",mm:t?"хвіліна_хвіліны_хвілін":"хвіліну_хвіліны_хвілін",hh:t?"гадзіна_гадзіны_гадзін":"гадзіну_гадзіны_гадзін",dd:"дзень_дні_дзён",MM:"месяц_месяцы_месяцаў",yy:"год_гады_гадоў"};return"m"===n?t?"хвіліна":"хвіліну":"h"===n?t?"гадзіна":"гадзіну":e+" "+(r=+e,a=o[n].split("_"),r%10==1&&r%100!=11?a[0]:r%10>=2&&r%10<=4&&(r%100<10||r%100>=20)?a[1]:a[2])}e.defineLocale("be",{months:{format:"студзеня_лютага_сакавіка_красавіка_траўня_чэрвеня_ліпеня_жніўня_верасня_кастрычніка_лістапада_снежня".split("_"),standalone:"студзень_люты_сакавік_красавік_травень_чэрвень_ліпень_жнівень_верасень_кастрычнік_лістапад_снежань".split("_")},monthsShort:"студ_лют_сак_крас_трав_чэрв_ліп_жнів_вер_каст_ліст_снеж".split("_"),weekdays:{format:"нядзелю_панядзелак_аўторак_сераду_чацвер_пятніцу_суботу".split("_"),standalone:"нядзеля_панядзелак_аўторак_серада_чацвер_пятніца_субота".split("_"),isFormat:/\[ ?[Ууў] ?(?:мінулую|наступную)? ?\] ?dddd/},weekdaysShort:"нд_пн_ат_ср_чц_пт_сб".split("_"),weekdaysMin:"нд_пн_ат_ср_чц_пт_сб".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY г.",LLL:"D MMMM YYYY г., HH:mm",LLLL:"dddd, D MMMM YYYY г., HH:mm"},calendar:{sameDay:"[Сёння ў] LT",nextDay:"[Заўтра ў] LT",lastDay:"[Учора ў] LT",nextWeek:function(){return"[У] dddd [ў] LT"},lastWeek:function(){switch(this.day()){case 0:case 3:case 5:case 6:return"[У мінулую] dddd [ў] LT";case 1:case 2:case 4:return"[У мінулы] dddd [ў] LT"}},sameElse:"L"},relativeTime:{future:"праз %s",past:"%s таму",s:"некалькі секунд",m:t,mm:t,h:t,hh:t,d:"дзень",dd:t,M:"месяц",MM:t,y:"год",yy:t},meridiemParse:/ночы|раніцы|дня|вечара/,isPM:function(e){return/^(дня|вечара)$/.test(e)},meridiem:function(e,t,n){return e<4?"ночы":e<12?"раніцы":e<17?"дня":"вечара"},dayOfMonthOrdinalParse:/\d{1,2}-(і|ы|га)/,ordinal:function(e,t){switch(t){case"M":case"d":case"DDD":case"w":case"W":return e%10!=2&&e%10!=3||e%100==12||e%100==13?e+"-ы":e+"-і";case"D":return e+"-га";default:return e}},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("bg",{months:"януари_февруари_март_април_май_юни_юли_август_септември_октомври_ноември_декември".split("_"),monthsShort:"янр_фев_мар_апр_май_юни_юли_авг_сеп_окт_ное_дек".split("_"),weekdays:"неделя_понеделник_вторник_сряда_четвъртък_петък_събота".split("_"),weekdaysShort:"нед_пон_вто_сря_чет_пет_съб".split("_"),weekdaysMin:"нд_пн_вт_ср_чт_пт_сб".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"D.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY H:mm",LLLL:"dddd, D MMMM YYYY H:mm"},calendar:{sameDay:"[Днес в] LT",nextDay:"[Утре в] LT",nextWeek:"dddd [в] LT",lastDay:"[Вчера в] LT",lastWeek:function(){switch(this.day()){case 0:case 3:case 6:return"[В изминалата] dddd [в] LT";case 1:case 2:case 4:case 5:return"[В изминалия] dddd [в] LT"}},sameElse:"L"},relativeTime:{future:"след %s",past:"преди %s",s:"няколко секунди",ss:"%d секунди",m:"минута",mm:"%d минути",h:"час",hh:"%d часа",d:"ден",dd:"%d дни",M:"месец",MM:"%d месеца",y:"година",yy:"%d години"},dayOfMonthOrdinalParse:/\d{1,2}-(ев|ен|ти|ви|ри|ми)/,ordinal:function(e){var t=e%10,n=e%100;return 0===e?e+"-ев":0===n?e+"-ен":n>10&&n<20?e+"-ти":1===t?e+"-ви":2===t?e+"-ри":7===t||8===t?e+"-ми":e+"-ти"},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("bm",{months:"Zanwuyekalo_Fewuruyekalo_Marisikalo_Awirilikalo_Mɛkalo_Zuwɛnkalo_Zuluyekalo_Utikalo_Sɛtanburukalo_ɔkutɔburukalo_Nowanburukalo_Desanburukalo".split("_"),monthsShort:"Zan_Few_Mar_Awi_Mɛ_Zuw_Zul_Uti_Sɛt_ɔku_Now_Des".split("_"),weekdays:"Kari_Ntɛnɛn_Tarata_Araba_Alamisa_Juma_Sibiri".split("_"),weekdaysShort:"Kar_Ntɛ_Tar_Ara_Ala_Jum_Sib".split("_"),weekdaysMin:"Ka_Nt_Ta_Ar_Al_Ju_Si".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"MMMM [tile] D [san] YYYY",LLL:"MMMM [tile] D [san] YYYY [lɛrɛ] HH:mm",LLLL:"dddd MMMM [tile] D [san] YYYY [lɛrɛ] HH:mm"},calendar:{sameDay:"[Bi lɛrɛ] LT",nextDay:"[Sini lɛrɛ] LT",nextWeek:"dddd [don lɛrɛ] LT",lastDay:"[Kunu lɛrɛ] LT",lastWeek:"dddd [tɛmɛnen lɛrɛ] LT",sameElse:"L"},relativeTime:{future:"%s kɔnɔ",past:"a bɛ %s bɔ",s:"sanga dama dama",ss:"sekondi %d",m:"miniti kelen",mm:"miniti %d",h:"lɛrɛ kelen",hh:"lɛrɛ %d",d:"tile kelen",dd:"tile %d",M:"kalo kelen",MM:"kalo %d",y:"san kelen",yy:"san %d"},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"১",2:"২",3:"৩",4:"৪",5:"৫",6:"৬",7:"৭",8:"৮",9:"৯",0:"০"},n={"১":"1","২":"2","৩":"3","৪":"4","৫":"5","৬":"6","৭":"7","৮":"8","৯":"9","০":"0"};e.defineLocale("bn",{months:"জানুয়ারী_ফেব্রুয়ারি_মার্চ_এপ্রিল_মে_জুন_জুলাই_আগস্ট_সেপ্টেম্বর_অক্টোবর_নভেম্বর_ডিসেম্বর".split("_"),monthsShort:"জানু_ফেব_মার্চ_এপ্র_মে_জুন_জুল_আগ_সেপ্ট_অক্টো_নভে_ডিসে".split("_"),weekdays:"রবিবার_সোমবার_মঙ্গলবার_বুধবার_বৃহস্পতিবার_শুক্রবার_শনিবার".split("_"),weekdaysShort:"রবি_সোম_মঙ্গল_বুধ_বৃহস্পতি_শুক্র_শনি".split("_"),weekdaysMin:"রবি_সোম_মঙ্গ_বুধ_বৃহঃ_শুক্র_শনি".split("_"),longDateFormat:{LT:"A h:mm সময়",LTS:"A h:mm:ss সময়",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm সময়",LLLL:"dddd, D MMMM YYYY, A h:mm সময়"},calendar:{sameDay:"[আজ] LT",nextDay:"[আগামীকাল] LT",nextWeek:"dddd, LT",lastDay:"[গতকাল] LT",lastWeek:"[গত] dddd, LT",sameElse:"L"},relativeTime:{future:"%s পরে",past:"%s আগে",s:"কয়েক সেকেন্ড",ss:"%d সেকেন্ড",m:"এক মিনিট",mm:"%d মিনিট",h:"এক ঘন্টা",hh:"%d ঘন্টা",d:"এক দিন",dd:"%d দিন",M:"এক মাস",MM:"%d মাস",y:"এক বছর",yy:"%d বছর"},preparse:function(e){return e.replace(/[১২৩৪৫৬৭৮৯০]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/রাত|সকাল|দুপুর|বিকাল|রাত/,meridiemHour:function(e,t){return 12===e&&(e=0),"রাত"===t&&e>=4||"দুপুর"===t&&e<5||"বিকাল"===t?e+12:e},meridiem:function(e,t,n){return e<4?"রাত":e<10?"সকাল":e<17?"দুপুর":e<20?"বিকাল":"রাত"},week:{dow:0,doy:6}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"༡",2:"༢",3:"༣",4:"༤",5:"༥",6:"༦",7:"༧",8:"༨",9:"༩",0:"༠"},n={"༡":"1","༢":"2","༣":"3","༤":"4","༥":"5","༦":"6","༧":"7","༨":"8","༩":"9","༠":"0"};e.defineLocale("bo",{months:"ཟླ་བ་དང་པོ_ཟླ་བ་གཉིས་པ_ཟླ་བ་གསུམ་པ_ཟླ་བ་བཞི་པ_ཟླ་བ་ལྔ་པ_ཟླ་བ་དྲུག་པ_ཟླ་བ་བདུན་པ_ཟླ་བ་བརྒྱད་པ_ཟླ་བ་དགུ་པ_ཟླ་བ་བཅུ་པ_ཟླ་བ་བཅུ་གཅིག་པ_ཟླ་བ་བཅུ་གཉིས་པ".split("_"),monthsShort:"ཟླ་བ་དང་པོ_ཟླ་བ་གཉིས་པ_ཟླ་བ་གསུམ་པ_ཟླ་བ་བཞི་པ_ཟླ་བ་ལྔ་པ_ཟླ་བ་དྲུག་པ_ཟླ་བ་བདུན་པ_ཟླ་བ་བརྒྱད་པ_ཟླ་བ་དགུ་པ_ཟླ་བ་བཅུ་པ_ཟླ་བ་བཅུ་གཅིག་པ_ཟླ་བ་བཅུ་གཉིས་པ".split("_"),weekdays:"གཟའ་ཉི་མ་_གཟའ་ཟླ་བ་_གཟའ་མིག་དམར་_གཟའ་ལྷག་པ་_གཟའ་ཕུར་བུ_གཟའ་པ་སངས་_གཟའ་སྤེན་པ་".split("_"),weekdaysShort:"ཉི་མ་_ཟླ་བ་_མིག་དམར་_ལྷག་པ་_ཕུར་བུ_པ་སངས་_སྤེན་པ་".split("_"),weekdaysMin:"ཉི་མ་_ཟླ་བ་_མིག་དམར་_ལྷག་པ་_ཕུར་བུ_པ་སངས་_སྤེན་པ་".split("_"),longDateFormat:{LT:"A h:mm",LTS:"A h:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm",LLLL:"dddd, D MMMM YYYY, A h:mm"},calendar:{sameDay:"[དི་རིང] LT",nextDay:"[སང་ཉིན] LT",nextWeek:"[བདུན་ཕྲག་རྗེས་མ], LT",lastDay:"[ཁ་སང] LT",lastWeek:"[བདུན་ཕྲག་མཐའ་མ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s ལ་",past:"%s སྔན་ལ",s:"ལམ་སང",ss:"%d སྐར་ཆ།",m:"སྐར་མ་གཅིག",mm:"%d སྐར་མ",h:"ཆུ་ཚོད་གཅིག",hh:"%d ཆུ་ཚོད",d:"ཉིན་གཅིག",dd:"%d ཉིན་",M:"ཟླ་བ་གཅིག",MM:"%d ཟླ་བ",y:"ལོ་གཅིག",yy:"%d ལོ"},preparse:function(e){return e.replace(/[༡༢༣༤༥༦༧༨༩༠]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/མཚན་མོ|ཞོགས་ཀས|ཉིན་གུང|དགོང་དག|མཚན་མོ/,meridiemHour:function(e,t){return 12===e&&(e=0),"མཚན་མོ"===t&&e>=4||"ཉིན་གུང"===t&&e<5||"དགོང་དག"===t?e+12:e},meridiem:function(e,t,n){return e<4?"མཚན་མོ":e<10?"ཞོགས་ཀས":e<17?"ཉིན་གུང":e<20?"དགོང་དག":"མཚན་མོ"},week:{dow:0,doy:6}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n){return e+" "+function(e,t){return 2===t?function(e){var t={m:"v",b:"v",d:"z"};return void 0===t[e.charAt(0)]?e:t[e.charAt(0)]+e.substring(1)}(e):e}({mm:"munutenn",MM:"miz",dd:"devezh"}[n],e)}e.defineLocale("br",{months:"Genver_C'hwevrer_Meurzh_Ebrel_Mae_Mezheven_Gouere_Eost_Gwengolo_Here_Du_Kerzu".split("_"),monthsShort:"Gen_C'hwe_Meu_Ebr_Mae_Eve_Gou_Eos_Gwe_Her_Du_Ker".split("_"),weekdays:"Sul_Lun_Meurzh_Merc'her_Yaou_Gwener_Sadorn".split("_"),weekdaysShort:"Sul_Lun_Meu_Mer_Yao_Gwe_Sad".split("_"),weekdaysMin:"Su_Lu_Me_Mer_Ya_Gw_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"h[e]mm A",LTS:"h[e]mm:ss A",L:"DD/MM/YYYY",LL:"D [a viz] MMMM YYYY",LLL:"D [a viz] MMMM YYYY h[e]mm A",LLLL:"dddd, D [a viz] MMMM YYYY h[e]mm A"},calendar:{sameDay:"[Hiziv da] LT",nextDay:"[Warc'hoazh da] LT",nextWeek:"dddd [da] LT",lastDay:"[Dec'h da] LT",lastWeek:"dddd [paset da] LT",sameElse:"L"},relativeTime:{future:"a-benn %s",past:"%s 'zo",s:"un nebeud segondennoù",ss:"%d eilenn",m:"ur vunutenn",mm:t,h:"un eur",hh:"%d eur",d:"un devezh",dd:t,M:"ur miz",MM:t,y:"ur bloaz",yy:function(e){switch(function e(t){return t>9?e(t%10):t}(e)){case 1:case 3:case 4:case 5:case 9:return e+" bloaz";default:return e+" vloaz"}}},dayOfMonthOrdinalParse:/\d{1,2}(añ|vet)/,ordinal:function(e){var t=1===e?"añ":"vet";return e+t},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n){var r=e+" ";switch(n){case"ss":return r+=1===e?"sekunda":2===e||3===e||4===e?"sekunde":"sekundi";case"m":return t?"jedna minuta":"jedne minute";case"mm":return r+=1===e?"minuta":2===e||3===e||4===e?"minute":"minuta";case"h":return t?"jedan sat":"jednog sata";case"hh":return r+=1===e?"sat":2===e||3===e||4===e?"sata":"sati";case"dd":return r+=1===e?"dan":"dana";case"MM":return r+=1===e?"mjesec":2===e||3===e||4===e?"mjeseca":"mjeseci";case"yy":return r+=1===e?"godina":2===e||3===e||4===e?"godine":"godina"}}e.defineLocale("bs",{months:"januar_februar_mart_april_maj_juni_juli_august_septembar_oktobar_novembar_decembar".split("_"),monthsShort:"jan._feb._mar._apr._maj._jun._jul._aug._sep._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sri._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd, D. MMMM YYYY H:mm"},calendar:{sameDay:"[danas u] LT",nextDay:"[sutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedjelju] [u] LT";case 3:return"[u] [srijedu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[jučer u] LT",lastWeek:function(){switch(this.day()){case 0:case 3:return"[prošlu] dddd [u] LT";case 6:return"[prošle] [subote] [u] LT";case 1:case 2:case 4:case 5:return"[prošli] dddd [u] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"prije %s",s:"par sekundi",ss:t,m:t,mm:t,h:t,hh:t,d:"dan",dd:t,M:"mjesec",MM:t,y:"godinu",yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ca",{months:{standalone:"gener_febrer_març_abril_maig_juny_juliol_agost_setembre_octubre_novembre_desembre".split("_"),format:"de gener_de febrer_de març_d'abril_de maig_de juny_de juliol_d'agost_de setembre_d'octubre_de novembre_de desembre".split("_"),isFormat:/D[oD]?(\s)+MMMM/},monthsShort:"gen._febr._març_abr._maig_juny_jul._ag._set._oct._nov._des.".split("_"),monthsParseExact:!0,weekdays:"diumenge_dilluns_dimarts_dimecres_dijous_divendres_dissabte".split("_"),weekdaysShort:"dg._dl._dt._dc._dj._dv._ds.".split("_"),weekdaysMin:"dg_dl_dt_dc_dj_dv_ds".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM [de] YYYY",ll:"D MMM YYYY",LLL:"D MMMM [de] YYYY [a les] H:mm",lll:"D MMM YYYY, H:mm",LLLL:"dddd D MMMM [de] YYYY [a les] H:mm",llll:"ddd D MMM YYYY, H:mm"},calendar:{sameDay:function(){return"[avui a "+(1!==this.hours()?"les":"la")+"] LT"},nextDay:function(){return"[demà a "+(1!==this.hours()?"les":"la")+"] LT"},nextWeek:function(){return"dddd [a "+(1!==this.hours()?"les":"la")+"] LT"},lastDay:function(){return"[ahir a "+(1!==this.hours()?"les":"la")+"] LT"},lastWeek:function(){return"[el] dddd [passat a "+(1!==this.hours()?"les":"la")+"] LT"},sameElse:"L"},relativeTime:{future:"d'aquí %s",past:"fa %s",s:"uns segons",ss:"%d segons",m:"un minut",mm:"%d minuts",h:"una hora",hh:"%d hores",d:"un dia",dd:"%d dies",M:"un mes",MM:"%d mesos",y:"un any",yy:"%d anys"},dayOfMonthOrdinalParse:/\d{1,2}(r|n|t|è|a)/,ordinal:function(e,t){var n=1===e?"r":2===e?"n":3===e?"r":4===e?"t":"è";return"w"!==t&&"W"!==t||(n="a"),e+n},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t="leden_únor_březen_duben_květen_červen_červenec_srpen_září_říjen_listopad_prosinec".split("_"),n="led_úno_bře_dub_kvě_čvn_čvc_srp_zář_říj_lis_pro".split("_"),r=[/^led/i,/^úno/i,/^bře/i,/^dub/i,/^kvě/i,/^(čvn|červen$|června)/i,/^(čvc|červenec|července)/i,/^srp/i,/^zář/i,/^říj/i,/^lis/i,/^pro/i],a=/^(leden|únor|březen|duben|květen|červenec|července|červen|června|srpen|září|říjen|listopad|prosinec|led|úno|bře|dub|kvě|čvn|čvc|srp|zář|říj|lis|pro)/i;function o(e){return e>1&&e<5&&1!=~~(e/10)}function i(e,t,n,r){var a=e+" ";switch(n){case"s":return t||r?"pár sekund":"pár sekundami";case"ss":return t||r?a+(o(e)?"sekundy":"sekund"):a+"sekundami";case"m":return t?"minuta":r?"minutu":"minutou";case"mm":return t||r?a+(o(e)?"minuty":"minut"):a+"minutami";case"h":return t?"hodina":r?"hodinu":"hodinou";case"hh":return t||r?a+(o(e)?"hodiny":"hodin"):a+"hodinami";case"d":return t||r?"den":"dnem";case"dd":return t||r?a+(o(e)?"dny":"dní"):a+"dny";case"M":return t||r?"měsíc":"měsícem";case"MM":return t||r?a+(o(e)?"měsíce":"měsíců"):a+"měsíci";case"y":return t||r?"rok":"rokem";case"yy":return t||r?a+(o(e)?"roky":"let"):a+"lety"}}e.defineLocale("cs",{months:t,monthsShort:n,monthsRegex:a,monthsShortRegex:a,monthsStrictRegex:/^(leden|ledna|února|únor|březen|března|duben|dubna|květen|května|červenec|července|červen|června|srpen|srpna|září|říjen|října|listopadu|listopad|prosinec|prosince)/i,monthsShortStrictRegex:/^(led|úno|bře|dub|kvě|čvn|čvc|srp|zář|říj|lis|pro)/i,monthsParse:r,longMonthsParse:r,shortMonthsParse:r,weekdays:"neděle_pondělí_úterý_středa_čtvrtek_pátek_sobota".split("_"),weekdaysShort:"ne_po_út_st_čt_pá_so".split("_"),weekdaysMin:"ne_po_út_st_čt_pá_so".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd D. MMMM YYYY H:mm",l:"D. M. YYYY"},calendar:{sameDay:"[dnes v] LT",nextDay:"[zítra v] LT",nextWeek:function(){switch(this.day()){case 0:return"[v neděli v] LT";case 1:case 2:return"[v] dddd [v] LT";case 3:return"[ve středu v] LT";case 4:return"[ve čtvrtek v] LT";case 5:return"[v pátek v] LT";case 6:return"[v sobotu v] LT"}},lastDay:"[včera v] LT",lastWeek:function(){switch(this.day()){case 0:return"[minulou neděli v] LT";case 1:case 2:return"[minulé] dddd [v] LT";case 3:return"[minulou středu v] LT";case 4:case 5:return"[minulý] dddd [v] LT";case 6:return"[minulou sobotu v] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"před %s",s:i,ss:i,m:i,mm:i,h:i,hh:i,d:i,dd:i,M:i,MM:i,y:i,yy:i},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("cv",{months:"кӑрлач_нарӑс_пуш_ака_май_ҫӗртме_утӑ_ҫурла_авӑн_юпа_чӳк_раштав".split("_"),monthsShort:"кӑр_нар_пуш_ака_май_ҫӗр_утӑ_ҫур_авн_юпа_чӳк_раш".split("_"),weekdays:"вырсарникун_тунтикун_ытларикун_юнкун_кӗҫнерникун_эрнекун_шӑматкун".split("_"),weekdaysShort:"выр_тун_ытл_юн_кӗҫ_эрн_шӑм".split("_"),weekdaysMin:"вр_тн_ыт_юн_кҫ_эр_шм".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD-MM-YYYY",LL:"YYYY [ҫулхи] MMMM [уйӑхӗн] D[-мӗшӗ]",LLL:"YYYY [ҫулхи] MMMM [уйӑхӗн] D[-мӗшӗ], HH:mm",LLLL:"dddd, YYYY [ҫулхи] MMMM [уйӑхӗн] D[-мӗшӗ], HH:mm"},calendar:{sameDay:"[Паян] LT [сехетре]",nextDay:"[Ыран] LT [сехетре]",lastDay:"[Ӗнер] LT [сехетре]",nextWeek:"[Ҫитес] dddd LT [сехетре]",lastWeek:"[Иртнӗ] dddd LT [сехетре]",sameElse:"L"},relativeTime:{future:function(e){var t=/сехет$/i.exec(e)?"рен":/ҫул$/i.exec(e)?"тан":"ран";return e+t},past:"%s каялла",s:"пӗр-ик ҫеккунт",ss:"%d ҫеккунт",m:"пӗр минут",mm:"%d минут",h:"пӗр сехет",hh:"%d сехет",d:"пӗр кун",dd:"%d кун",M:"пӗр уйӑх",MM:"%d уйӑх",y:"пӗр ҫул",yy:"%d ҫул"},dayOfMonthOrdinalParse:/\d{1,2}-мӗш/,ordinal:"%d-мӗш",week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("cy",{months:"Ionawr_Chwefror_Mawrth_Ebrill_Mai_Mehefin_Gorffennaf_Awst_Medi_Hydref_Tachwedd_Rhagfyr".split("_"),monthsShort:"Ion_Chwe_Maw_Ebr_Mai_Meh_Gor_Aws_Med_Hyd_Tach_Rhag".split("_"),weekdays:"Dydd Sul_Dydd Llun_Dydd Mawrth_Dydd Mercher_Dydd Iau_Dydd Gwener_Dydd Sadwrn".split("_"),weekdaysShort:"Sul_Llun_Maw_Mer_Iau_Gwe_Sad".split("_"),weekdaysMin:"Su_Ll_Ma_Me_Ia_Gw_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Heddiw am] LT",nextDay:"[Yfory am] LT",nextWeek:"dddd [am] LT",lastDay:"[Ddoe am] LT",lastWeek:"dddd [diwethaf am] LT",sameElse:"L"},relativeTime:{future:"mewn %s",past:"%s yn ôl",s:"ychydig eiliadau",ss:"%d eiliad",m:"munud",mm:"%d munud",h:"awr",hh:"%d awr",d:"diwrnod",dd:"%d diwrnod",M:"mis",MM:"%d mis",y:"blwyddyn",yy:"%d flynedd"},dayOfMonthOrdinalParse:/\d{1,2}(fed|ain|af|il|ydd|ed|eg)/,ordinal:function(e){var t=e,n="";return t>20?n=40===t||50===t||60===t||80===t||100===t?"fed":"ain":t>0&&(n=["","af","il","ydd","ydd","ed","ed","ed","fed","fed","fed","eg","fed","eg","eg","fed","eg","eg","fed","eg","fed"][t]),e+n},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("da",{months:"januar_februar_marts_april_maj_juni_juli_august_september_oktober_november_december".split("_"),monthsShort:"jan_feb_mar_apr_maj_jun_jul_aug_sep_okt_nov_dec".split("_"),weekdays:"søndag_mandag_tirsdag_onsdag_torsdag_fredag_lørdag".split("_"),weekdaysShort:"søn_man_tir_ons_tor_fre_lør".split("_"),weekdaysMin:"sø_ma_ti_on_to_fr_lø".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd [d.] D. MMMM YYYY [kl.] HH:mm"},calendar:{sameDay:"[i dag kl.] LT",nextDay:"[i morgen kl.] LT",nextWeek:"på dddd [kl.] LT",lastDay:"[i går kl.] LT",lastWeek:"[i] dddd[s kl.] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"%s siden",s:"få sekunder",ss:"%d sekunder",m:"et minut",mm:"%d minutter",h:"en time",hh:"%d timer",d:"en dag",dd:"%d dage",M:"en måned",MM:"%d måneder",y:"et år",yy:"%d år"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n,r){var a={m:["eine Minute","einer Minute"],h:["eine Stunde","einer Stunde"],d:["ein Tag","einem Tag"],dd:[e+" Tage",e+" Tagen"],M:["ein Monat","einem Monat"],MM:[e+" Monate",e+" Monaten"],y:["ein Jahr","einem Jahr"],yy:[e+" Jahre",e+" Jahren"]};return t?a[n][0]:a[n][1]}e.defineLocale("de",{months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.".split("_"),monthsParseExact:!0,weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},calendar:{sameDay:"[heute um] LT [Uhr]",sameElse:"L",nextDay:"[morgen um] LT [Uhr]",nextWeek:"dddd [um] LT [Uhr]",lastDay:"[gestern um] LT [Uhr]",lastWeek:"[letzten] dddd [um] LT [Uhr]"},relativeTime:{future:"in %s",past:"vor %s",s:"ein paar Sekunden",ss:"%d Sekunden",m:t,mm:"%d Minuten",h:t,hh:"%d Stunden",d:t,dd:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n,r){var a={m:["eine Minute","einer Minute"],h:["eine Stunde","einer Stunde"],d:["ein Tag","einem Tag"],dd:[e+" Tage",e+" Tagen"],M:["ein Monat","einem Monat"],MM:[e+" Monate",e+" Monaten"],y:["ein Jahr","einem Jahr"],yy:[e+" Jahre",e+" Jahren"]};return t?a[n][0]:a[n][1]}e.defineLocale("de-at",{months:"Jänner_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jän._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.".split("_"),monthsParseExact:!0,weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},calendar:{sameDay:"[heute um] LT [Uhr]",sameElse:"L",nextDay:"[morgen um] LT [Uhr]",nextWeek:"dddd [um] LT [Uhr]",lastDay:"[gestern um] LT [Uhr]",lastWeek:"[letzten] dddd [um] LT [Uhr]"},relativeTime:{future:"in %s",past:"vor %s",s:"ein paar Sekunden",ss:"%d Sekunden",m:t,mm:"%d Minuten",h:t,hh:"%d Stunden",d:t,dd:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n,r){var a={m:["eine Minute","einer Minute"],h:["eine Stunde","einer Stunde"],d:["ein Tag","einem Tag"],dd:[e+" Tage",e+" Tagen"],M:["ein Monat","einem Monat"],MM:[e+" Monate",e+" Monaten"],y:["ein Jahr","einem Jahr"],yy:[e+" Jahre",e+" Jahren"]};return t?a[n][0]:a[n][1]}e.defineLocale("de-ch",{months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.".split("_"),monthsParseExact:!0,weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},calendar:{sameDay:"[heute um] LT [Uhr]",sameElse:"L",nextDay:"[morgen um] LT [Uhr]",nextWeek:"dddd [um] LT [Uhr]",lastDay:"[gestern um] LT [Uhr]",lastWeek:"[letzten] dddd [um] LT [Uhr]"},relativeTime:{future:"in %s",past:"vor %s",s:"ein paar Sekunden",ss:"%d Sekunden",m:t,mm:"%d Minuten",h:t,hh:"%d Stunden",d:t,dd:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t=["ޖެނުއަރީ","ފެބްރުއަރީ","މާރިޗު","އޭޕްރީލު","މޭ","ޖޫން","ޖުލައި","އޯގަސްޓު","ސެޕްޓެމްބަރު","އޮކްޓޯބަރު","ނޮވެމްބަރު","ޑިސެމްބަރު"],n=["އާދިއްތަ","ހޯމަ","އަންގާރަ","ބުދަ","ބުރާސްފަތި","ހުކުރު","ހޮނިހިރު"];e.defineLocale("dv",{months:t,monthsShort:t,weekdays:n,weekdaysShort:n,weekdaysMin:"އާދި_ހޯމަ_އަން_ބުދަ_ބުރާ_ހުކު_ހޮނި".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"D/M/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},meridiemParse:/މކ|މފ/,isPM:function(e){return"މފ"===e},meridiem:function(e,t,n){return e<12?"މކ":"މފ"},calendar:{sameDay:"[މިއަދު] LT",nextDay:"[މާދަމާ] LT",nextWeek:"dddd LT",lastDay:"[އިއްޔެ] LT",lastWeek:"[ފާއިތުވި] dddd LT",sameElse:"L"},relativeTime:{future:"ތެރޭގައި %s",past:"ކުރިން %s",s:"ސިކުންތުކޮޅެއް",ss:"d% ސިކުންތު",m:"މިނިޓެއް",mm:"މިނިޓު %d",h:"ގަޑިއިރެއް",hh:"ގަޑިއިރު %d",d:"ދުވަހެއް",dd:"ދުވަސް %d",M:"މަހެއް",MM:"މަސް %d",y:"އަހަރެއް",yy:"އަހަރު %d"},preparse:function(e){return e.replace(/،/g,",")},postformat:function(e){return e.replace(/,/g,"،")},week:{dow:7,doy:12}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("el",{monthsNominativeEl:"Ιανουάριος_Φεβρουάριος_Μάρτιος_Απρίλιος_Μάιος_Ιούνιος_Ιούλιος_Αύγουστος_Σεπτέμβριος_Οκτώβριος_Νοέμβριος_Δεκέμβριος".split("_"),monthsGenitiveEl:"Ιανουαρίου_Φεβρουαρίου_Μαρτίου_Απριλίου_Μαΐου_Ιουνίου_Ιουλίου_Αυγούστου_Σεπτεμβρίου_Οκτωβρίου_Νοεμβρίου_Δεκεμβρίου".split("_"),months:function(e,t){return e?"string"==typeof t&&/D/.test(t.substring(0,t.indexOf("MMMM")))?this._monthsGenitiveEl[e.month()]:this._monthsNominativeEl[e.month()]:this._monthsNominativeEl},monthsShort:"Ιαν_Φεβ_Μαρ_Απρ_Μαϊ_Ιουν_Ιουλ_Αυγ_Σεπ_Οκτ_Νοε_Δεκ".split("_"),weekdays:"Κυριακή_Δευτέρα_Τρίτη_Τετάρτη_Πέμπτη_Παρασκευή_Σάββατο".split("_"),weekdaysShort:"Κυρ_Δευ_Τρι_Τετ_Πεμ_Παρ_Σαβ".split("_"),weekdaysMin:"Κυ_Δε_Τρ_Τε_Πε_Πα_Σα".split("_"),meridiem:function(e,t,n){return e>11?n?"μμ":"ΜΜ":n?"πμ":"ΠΜ"},isPM:function(e){return"μ"===(e+"").toLowerCase()[0]},meridiemParse:/[ΠΜ]\.?Μ?\.?/i,longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendarEl:{sameDay:"[Σήμερα {}] LT",nextDay:"[Αύριο {}] LT",nextWeek:"dddd [{}] LT",lastDay:"[Χθες {}] LT",lastWeek:function(){switch(this.day()){case 6:return"[το προηγούμενο] dddd [{}] LT";default:return"[την προηγούμενη] dddd [{}] LT"}},sameElse:"L"},calendar:function(e,t){var n,r=this._calendarEl[e],a=t&&t.hours();return((n=r)instanceof Function||"[object Function]"===Object.prototype.toString.call(n))&&(r=r.apply(t)),r.replace("{}",a%12==1?"στη":"στις")},relativeTime:{future:"σε %s",past:"%s πριν",s:"λίγα δευτερόλεπτα",ss:"%d δευτερόλεπτα",m:"ένα λεπτό",mm:"%d λεπτά",h:"μία ώρα",hh:"%d ώρες",d:"μία μέρα",dd:"%d μέρες",M:"ένας μήνας",MM:"%d μήνες",y:"ένας χρόνος",yy:"%d χρόνια"},dayOfMonthOrdinalParse:/\d{1,2}η/,ordinal:"%dη",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("en-SG",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10,n=1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+n},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("en-au",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10,n=1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+n},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("en-ca",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"YYYY-MM-DD",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10,n=1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+n}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("en-gb",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10,n=1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+n},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("en-ie",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10,n=1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+n},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("en-il",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10,n=1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+n}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("en-nz",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10,n=1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+n},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("eo",{months:"januaro_februaro_marto_aprilo_majo_junio_julio_aŭgusto_septembro_oktobro_novembro_decembro".split("_"),monthsShort:"jan_feb_mar_apr_maj_jun_jul_aŭg_sep_okt_nov_dec".split("_"),weekdays:"dimanĉo_lundo_mardo_merkredo_ĵaŭdo_vendredo_sabato".split("_"),weekdaysShort:"dim_lun_mard_merk_ĵaŭ_ven_sab".split("_"),weekdaysMin:"di_lu_ma_me_ĵa_ve_sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"D[-a de] MMMM, YYYY",LLL:"D[-a de] MMMM, YYYY HH:mm",LLLL:"dddd, [la] D[-a de] MMMM, YYYY HH:mm"},meridiemParse:/[ap]\.t\.m/i,isPM:function(e){return"p"===e.charAt(0).toLowerCase()},meridiem:function(e,t,n){return e>11?n?"p.t.m.":"P.T.M.":n?"a.t.m.":"A.T.M."},calendar:{sameDay:"[Hodiaŭ je] LT",nextDay:"[Morgaŭ je] LT",nextWeek:"dddd [je] LT",lastDay:"[Hieraŭ je] LT",lastWeek:"[pasinta] dddd [je] LT",sameElse:"L"},relativeTime:{future:"post %s",past:"antaŭ %s",s:"sekundoj",ss:"%d sekundoj",m:"minuto",mm:"%d minutoj",h:"horo",hh:"%d horoj",d:"tago",dd:"%d tagoj",M:"monato",MM:"%d monatoj",y:"jaro",yy:"%d jaroj"},dayOfMonthOrdinalParse:/\d{1,2}a/,ordinal:"%da",week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";var t="ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.".split("_"),n="ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),r=[/^ene/i,/^feb/i,/^mar/i,/^abr/i,/^may/i,/^jun/i,/^jul/i,/^ago/i,/^sep/i,/^oct/i,/^nov/i,/^dic/i],a=/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i;e.defineLocale("es",{months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),monthsShort:function(e,r){return e?/-MMM-/.test(r)?n[e.month()]:t[e.month()]:t},monthsRegex:a,monthsShortRegex:a,monthsStrictRegex:/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,monthsShortStrictRegex:/^(ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i,monthsParse:r,longMonthsParse:r,shortMonthsParse:r,weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY H:mm",LLLL:"dddd, D [de] MMMM [de] YYYY H:mm"},calendar:{sameDay:function(){return"[hoy a la"+(1!==this.hours()?"s":"")+"] LT"},nextDay:function(){return"[mañana a la"+(1!==this.hours()?"s":"")+"] LT"},nextWeek:function(){return"dddd [a la"+(1!==this.hours()?"s":"")+"] LT"},lastDay:function(){return"[ayer a la"+(1!==this.hours()?"s":"")+"] LT"},lastWeek:function(){return"[el] dddd [pasado a la"+(1!==this.hours()?"s":"")+"] LT"},sameElse:"L"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",ss:"%d segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t="ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.".split("_"),n="ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),r=[/^ene/i,/^feb/i,/^mar/i,/^abr/i,/^may/i,/^jun/i,/^jul/i,/^ago/i,/^sep/i,/^oct/i,/^nov/i,/^dic/i],a=/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i;e.defineLocale("es-do",{months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),monthsShort:function(e,r){return e?/-MMM-/.test(r)?n[e.month()]:t[e.month()]:t},monthsRegex:a,monthsShortRegex:a,monthsStrictRegex:/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,monthsShortStrictRegex:/^(ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i,monthsParse:r,longMonthsParse:r,shortMonthsParse:r,weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY h:mm A",LLLL:"dddd, D [de] MMMM [de] YYYY h:mm A"},calendar:{sameDay:function(){return"[hoy a la"+(1!==this.hours()?"s":"")+"] LT"},nextDay:function(){return"[mañana a la"+(1!==this.hours()?"s":"")+"] LT"},nextWeek:function(){return"dddd [a la"+(1!==this.hours()?"s":"")+"] LT"},lastDay:function(){return"[ayer a la"+(1!==this.hours()?"s":"")+"] LT"},lastWeek:function(){return"[el] dddd [pasado a la"+(1!==this.hours()?"s":"")+"] LT"},sameElse:"L"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",ss:"%d segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t="ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.".split("_"),n="ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),r=[/^ene/i,/^feb/i,/^mar/i,/^abr/i,/^may/i,/^jun/i,/^jul/i,/^ago/i,/^sep/i,/^oct/i,/^nov/i,/^dic/i],a=/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i;e.defineLocale("es-us",{months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),monthsShort:function(e,r){return e?/-MMM-/.test(r)?n[e.month()]:t[e.month()]:t},monthsRegex:a,monthsShortRegex:a,monthsStrictRegex:/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,monthsShortStrictRegex:/^(ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i,monthsParse:r,longMonthsParse:r,shortMonthsParse:r,weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"MM/DD/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY h:mm A",LLLL:"dddd, D [de] MMMM [de] YYYY h:mm A"},calendar:{sameDay:function(){return"[hoy a la"+(1!==this.hours()?"s":"")+"] LT"},nextDay:function(){return"[mañana a la"+(1!==this.hours()?"s":"")+"] LT"},nextWeek:function(){return"dddd [a la"+(1!==this.hours()?"s":"")+"] LT"},lastDay:function(){return"[ayer a la"+(1!==this.hours()?"s":"")+"] LT"},lastWeek:function(){return"[el] dddd [pasado a la"+(1!==this.hours()?"s":"")+"] LT"},sameElse:"L"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",ss:"%d segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:0,doy:6}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n,r){var a={s:["mõne sekundi","mõni sekund","paar sekundit"],ss:[e+"sekundi",e+"sekundit"],m:["ühe minuti","üks minut"],mm:[e+" minuti",e+" minutit"],h:["ühe tunni","tund aega","üks tund"],hh:[e+" tunni",e+" tundi"],d:["ühe päeva","üks päev"],M:["kuu aja","kuu aega","üks kuu"],MM:[e+" kuu",e+" kuud"],y:["ühe aasta","aasta","üks aasta"],yy:[e+" aasta",e+" aastat"]};return t?a[n][2]?a[n][2]:a[n][1]:r?a[n][0]:a[n][1]}e.defineLocale("et",{months:"jaanuar_veebruar_märts_aprill_mai_juuni_juuli_august_september_oktoober_november_detsember".split("_"),monthsShort:"jaan_veebr_märts_apr_mai_juuni_juuli_aug_sept_okt_nov_dets".split("_"),weekdays:"pühapäev_esmaspäev_teisipäev_kolmapäev_neljapäev_reede_laupäev".split("_"),weekdaysShort:"P_E_T_K_N_R_L".split("_"),weekdaysMin:"P_E_T_K_N_R_L".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd, D. MMMM YYYY H:mm"},calendar:{sameDay:"[Täna,] LT",nextDay:"[Homme,] LT",nextWeek:"[Järgmine] dddd LT",lastDay:"[Eile,] LT",lastWeek:"[Eelmine] dddd LT",sameElse:"L"},relativeTime:{future:"%s pärast",past:"%s tagasi",s:t,ss:t,m:t,mm:t,h:t,hh:t,d:t,dd:"%d päeva",M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("eu",{months:"urtarrila_otsaila_martxoa_apirila_maiatza_ekaina_uztaila_abuztua_iraila_urria_azaroa_abendua".split("_"),monthsShort:"urt._ots._mar._api._mai._eka._uzt._abu._ira._urr._aza._abe.".split("_"),monthsParseExact:!0,weekdays:"igandea_astelehena_asteartea_asteazkena_osteguna_ostirala_larunbata".split("_"),weekdaysShort:"ig._al._ar._az._og._ol._lr.".split("_"),weekdaysMin:"ig_al_ar_az_og_ol_lr".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"YYYY[ko] MMMM[ren] D[a]",LLL:"YYYY[ko] MMMM[ren] D[a] HH:mm",LLLL:"dddd, YYYY[ko] MMMM[ren] D[a] HH:mm",l:"YYYY-M-D",ll:"YYYY[ko] MMM D[a]",lll:"YYYY[ko] MMM D[a] HH:mm",llll:"ddd, YYYY[ko] MMM D[a] HH:mm"},calendar:{sameDay:"[gaur] LT[etan]",nextDay:"[bihar] LT[etan]",nextWeek:"dddd LT[etan]",lastDay:"[atzo] LT[etan]",lastWeek:"[aurreko] dddd LT[etan]",sameElse:"L"},relativeTime:{future:"%s barru",past:"duela %s",s:"segundo batzuk",ss:"%d segundo",m:"minutu bat",mm:"%d minutu",h:"ordu bat",hh:"%d ordu",d:"egun bat",dd:"%d egun",M:"hilabete bat",MM:"%d hilabete",y:"urte bat",yy:"%d urte"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"۱",2:"۲",3:"۳",4:"۴",5:"۵",6:"۶",7:"۷",8:"۸",9:"۹",0:"۰"},n={"۱":"1","۲":"2","۳":"3","۴":"4","۵":"5","۶":"6","۷":"7","۸":"8","۹":"9","۰":"0"};e.defineLocale("fa",{months:"ژانویه_فوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر".split("_"),monthsShort:"ژانویه_فوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر".split("_"),weekdays:"یک‌شنبه_دوشنبه_سه‌شنبه_چهارشنبه_پنج‌شنبه_جمعه_شنبه".split("_"),weekdaysShort:"یک‌شنبه_دوشنبه_سه‌شنبه_چهارشنبه_پنج‌شنبه_جمعه_شنبه".split("_"),weekdaysMin:"ی_د_س_چ_پ_ج_ش".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},meridiemParse:/قبل از ظهر|بعد از ظهر/,isPM:function(e){return/بعد از ظهر/.test(e)},meridiem:function(e,t,n){return e<12?"قبل از ظهر":"بعد از ظهر"},calendar:{sameDay:"[امروز ساعت] LT",nextDay:"[فردا ساعت] LT",nextWeek:"dddd [ساعت] LT",lastDay:"[دیروز ساعت] LT",lastWeek:"dddd [پیش] [ساعت] LT",sameElse:"L"},relativeTime:{future:"در %s",past:"%s پیش",s:"چند ثانیه",ss:"ثانیه d%",m:"یک دقیقه",mm:"%d دقیقه",h:"یک ساعت",hh:"%d ساعت",d:"یک روز",dd:"%d روز",M:"یک ماه",MM:"%d ماه",y:"یک سال",yy:"%d سال"},preparse:function(e){return e.replace(/[۰-۹]/g,function(e){return n[e]}).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]}).replace(/,/g,"،")},dayOfMonthOrdinalParse:/\d{1,2}م/,ordinal:"%dم",week:{dow:6,doy:12}})}(n(8))},function(e,t,n){!function(e){"use strict";var t="nolla yksi kaksi kolme neljä viisi kuusi seitsemän kahdeksan yhdeksän".split(" "),n=["nolla","yhden","kahden","kolmen","neljän","viiden","kuuden",t[7],t[8],t[9]];function r(e,r,a,o){var i="";switch(a){case"s":return o?"muutaman sekunnin":"muutama sekunti";case"ss":return o?"sekunnin":"sekuntia";case"m":return o?"minuutin":"minuutti";case"mm":i=o?"minuutin":"minuuttia";break;case"h":return o?"tunnin":"tunti";case"hh":i=o?"tunnin":"tuntia";break;case"d":return o?"päivän":"päivä";case"dd":i=o?"päivän":"päivää";break;case"M":return o?"kuukauden":"kuukausi";case"MM":i=o?"kuukauden":"kuukautta";break;case"y":return o?"vuoden":"vuosi";case"yy":i=o?"vuoden":"vuotta"}return i=function(e,r){return e<10?r?n[e]:t[e]:e}(e,o)+" "+i}e.defineLocale("fi",{months:"tammikuu_helmikuu_maaliskuu_huhtikuu_toukokuu_kesäkuu_heinäkuu_elokuu_syyskuu_lokakuu_marraskuu_joulukuu".split("_"),monthsShort:"tammi_helmi_maalis_huhti_touko_kesä_heinä_elo_syys_loka_marras_joulu".split("_"),weekdays:"sunnuntai_maanantai_tiistai_keskiviikko_torstai_perjantai_lauantai".split("_"),weekdaysShort:"su_ma_ti_ke_to_pe_la".split("_"),weekdaysMin:"su_ma_ti_ke_to_pe_la".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD.MM.YYYY",LL:"Do MMMM[ta] YYYY",LLL:"Do MMMM[ta] YYYY, [klo] HH.mm",LLLL:"dddd, Do MMMM[ta] YYYY, [klo] HH.mm",l:"D.M.YYYY",ll:"Do MMM YYYY",lll:"Do MMM YYYY, [klo] HH.mm",llll:"ddd, Do MMM YYYY, [klo] HH.mm"},calendar:{sameDay:"[tänään] [klo] LT",nextDay:"[huomenna] [klo] LT",nextWeek:"dddd [klo] LT",lastDay:"[eilen] [klo] LT",lastWeek:"[viime] dddd[na] [klo] LT",sameElse:"L"},relativeTime:{future:"%s päästä",past:"%s sitten",s:r,ss:r,m:r,mm:r,h:r,hh:r,d:r,dd:r,M:r,MM:r,y:r,yy:r},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("fo",{months:"januar_februar_mars_apríl_mai_juni_juli_august_september_oktober_november_desember".split("_"),monthsShort:"jan_feb_mar_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_"),weekdays:"sunnudagur_mánadagur_týsdagur_mikudagur_hósdagur_fríggjadagur_leygardagur".split("_"),weekdaysShort:"sun_mán_týs_mik_hós_frí_ley".split("_"),weekdaysMin:"su_má_tý_mi_hó_fr_le".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D. MMMM, YYYY HH:mm"},calendar:{sameDay:"[Í dag kl.] LT",nextDay:"[Í morgin kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[Í gjár kl.] LT",lastWeek:"[síðstu] dddd [kl] LT",sameElse:"L"},relativeTime:{future:"um %s",past:"%s síðani",s:"fá sekund",ss:"%d sekundir",m:"ein minuttur",mm:"%d minuttir",h:"ein tími",hh:"%d tímar",d:"ein dagur",dd:"%d dagar",M:"ein mánaður",MM:"%d mánaðir",y:"eitt ár",yy:"%d ár"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("fr",{months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),monthsParseExact:!0,weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Aujourd’hui à] LT",nextDay:"[Demain à] LT",nextWeek:"dddd [à] LT",lastDay:"[Hier à] LT",lastWeek:"dddd [dernier à] LT",sameElse:"L"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",ss:"%d secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},dayOfMonthOrdinalParse:/\d{1,2}(er|)/,ordinal:function(e,t){switch(t){case"D":return e+(1===e?"er":"");default:case"M":case"Q":case"DDD":case"d":return e+(1===e?"er":"e");case"w":case"W":return e+(1===e?"re":"e")}},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("fr-ca",{months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),monthsParseExact:!0,weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Aujourd’hui à] LT",nextDay:"[Demain à] LT",nextWeek:"dddd [à] LT",lastDay:"[Hier à] LT",lastWeek:"dddd [dernier à] LT",sameElse:"L"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",ss:"%d secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},dayOfMonthOrdinalParse:/\d{1,2}(er|e)/,ordinal:function(e,t){switch(t){default:case"M":case"Q":case"D":case"DDD":case"d":return e+(1===e?"er":"e");case"w":case"W":return e+(1===e?"re":"e")}}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("fr-ch",{months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),monthsParseExact:!0,weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Aujourd’hui à] LT",nextDay:"[Demain à] LT",nextWeek:"dddd [à] LT",lastDay:"[Hier à] LT",lastWeek:"dddd [dernier à] LT",sameElse:"L"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",ss:"%d secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},dayOfMonthOrdinalParse:/\d{1,2}(er|e)/,ordinal:function(e,t){switch(t){default:case"M":case"Q":case"D":case"DDD":case"d":return e+(1===e?"er":"e");case"w":case"W":return e+(1===e?"re":"e")}},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t="jan._feb._mrt._apr._mai_jun._jul._aug._sep._okt._nov._des.".split("_"),n="jan_feb_mrt_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_");e.defineLocale("fy",{months:"jannewaris_febrewaris_maart_april_maaie_juny_july_augustus_septimber_oktober_novimber_desimber".split("_"),monthsShort:function(e,r){return e?/-MMM-/.test(r)?n[e.month()]:t[e.month()]:t},monthsParseExact:!0,weekdays:"snein_moandei_tiisdei_woansdei_tongersdei_freed_sneon".split("_"),weekdaysShort:"si._mo._ti._wo._to._fr._so.".split("_"),weekdaysMin:"Si_Mo_Ti_Wo_To_Fr_So".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD-MM-YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[hjoed om] LT",nextDay:"[moarn om] LT",nextWeek:"dddd [om] LT",lastDay:"[juster om] LT",lastWeek:"[ôfrûne] dddd [om] LT",sameElse:"L"},relativeTime:{future:"oer %s",past:"%s lyn",s:"in pear sekonden",ss:"%d sekonden",m:"ien minút",mm:"%d minuten",h:"ien oere",hh:"%d oeren",d:"ien dei",dd:"%d dagen",M:"ien moanne",MM:"%d moannen",y:"ien jier",yy:"%d jierren"},dayOfMonthOrdinalParse:/\d{1,2}(ste|de)/,ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ga",{months:["Eanáir","Feabhra","Márta","Aibreán","Bealtaine","Méitheamh","Iúil","Lúnasa","Meán Fómhair","Deaireadh Fómhair","Samhain","Nollaig"],monthsShort:["Eaná","Feab","Márt","Aibr","Beal","Méit","Iúil","Lúna","Meán","Deai","Samh","Noll"],monthsParseExact:!0,weekdays:["Dé Domhnaigh","Dé Luain","Dé Máirt","Dé Céadaoin","Déardaoin","Dé hAoine","Dé Satharn"],weekdaysShort:["Dom","Lua","Mái","Céa","Déa","hAo","Sat"],weekdaysMin:["Do","Lu","Má","Ce","Dé","hA","Sa"],longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Inniu ag] LT",nextDay:"[Amárach ag] LT",nextWeek:"dddd [ag] LT",lastDay:"[Inné aig] LT",lastWeek:"dddd [seo caite] [ag] LT",sameElse:"L"},relativeTime:{future:"i %s",past:"%s ó shin",s:"cúpla soicind",ss:"%d soicind",m:"nóiméad",mm:"%d nóiméad",h:"uair an chloig",hh:"%d uair an chloig",d:"lá",dd:"%d lá",M:"mí",MM:"%d mí",y:"bliain",yy:"%d bliain"},dayOfMonthOrdinalParse:/\d{1,2}(d|na|mh)/,ordinal:function(e){var t=1===e?"d":e%10==2?"na":"mh";return e+t},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("gd",{months:["Am Faoilleach","An Gearran","Am Màrt","An Giblean","An Cèitean","An t-Ògmhios","An t-Iuchar","An Lùnastal","An t-Sultain","An Dàmhair","An t-Samhain","An Dùbhlachd"],monthsShort:["Faoi","Gear","Màrt","Gibl","Cèit","Ògmh","Iuch","Lùn","Sult","Dàmh","Samh","Dùbh"],monthsParseExact:!0,weekdays:["Didòmhnaich","Diluain","Dimàirt","Diciadain","Diardaoin","Dihaoine","Disathairne"],weekdaysShort:["Did","Dil","Dim","Dic","Dia","Dih","Dis"],weekdaysMin:["Dò","Lu","Mà","Ci","Ar","Ha","Sa"],longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[An-diugh aig] LT",nextDay:"[A-màireach aig] LT",nextWeek:"dddd [aig] LT",lastDay:"[An-dè aig] LT",lastWeek:"dddd [seo chaidh] [aig] LT",sameElse:"L"},relativeTime:{future:"ann an %s",past:"bho chionn %s",s:"beagan diogan",ss:"%d diogan",m:"mionaid",mm:"%d mionaidean",h:"uair",hh:"%d uairean",d:"latha",dd:"%d latha",M:"mìos",MM:"%d mìosan",y:"bliadhna",yy:"%d bliadhna"},dayOfMonthOrdinalParse:/\d{1,2}(d|na|mh)/,ordinal:function(e){var t=1===e?"d":e%10==2?"na":"mh";return e+t},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("gl",{months:"xaneiro_febreiro_marzo_abril_maio_xuño_xullo_agosto_setembro_outubro_novembro_decembro".split("_"),monthsShort:"xan._feb._mar._abr._mai._xuñ._xul._ago._set._out._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"domingo_luns_martes_mércores_xoves_venres_sábado".split("_"),weekdaysShort:"dom._lun._mar._mér._xov._ven._sáb.".split("_"),weekdaysMin:"do_lu_ma_mé_xo_ve_sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY H:mm",LLLL:"dddd, D [de] MMMM [de] YYYY H:mm"},calendar:{sameDay:function(){return"[hoxe "+(1!==this.hours()?"ás":"á")+"] LT"},nextDay:function(){return"[mañá "+(1!==this.hours()?"ás":"á")+"] LT"},nextWeek:function(){return"dddd ["+(1!==this.hours()?"ás":"a")+"] LT"},lastDay:function(){return"[onte "+(1!==this.hours()?"á":"a")+"] LT"},lastWeek:function(){return"[o] dddd [pasado "+(1!==this.hours()?"ás":"a")+"] LT"},sameElse:"L"},relativeTime:{future:function(e){return 0===e.indexOf("un")?"n"+e:"en "+e},past:"hai %s",s:"uns segundos",ss:"%d segundos",m:"un minuto",mm:"%d minutos",h:"unha hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un ano",yy:"%d anos"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n,r){var a={s:["thodde secondanim","thodde second"],ss:[e+" secondanim",e+" second"],m:["eka mintan","ek minute"],mm:[e+" mintanim",e+" mintam"],h:["eka voran","ek vor"],hh:[e+" voranim",e+" voram"],d:["eka disan","ek dis"],dd:[e+" disanim",e+" dis"],M:["eka mhoinean","ek mhoino"],MM:[e+" mhoineanim",e+" mhoine"],y:["eka vorsan","ek voros"],yy:[e+" vorsanim",e+" vorsam"]};return t?a[n][0]:a[n][1]}e.defineLocale("gom-latn",{months:"Janer_Febrer_Mars_Abril_Mai_Jun_Julai_Agost_Setembr_Otubr_Novembr_Dezembr".split("_"),monthsShort:"Jan._Feb._Mars_Abr._Mai_Jun_Jul._Ago._Set._Otu._Nov._Dez.".split("_"),monthsParseExact:!0,weekdays:"Aitar_Somar_Mongllar_Budvar_Brestar_Sukrar_Son'var".split("_"),weekdaysShort:"Ait._Som._Mon._Bud._Bre._Suk._Son.".split("_"),weekdaysMin:"Ai_Sm_Mo_Bu_Br_Su_Sn".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"A h:mm [vazta]",LTS:"A h:mm:ss [vazta]",L:"DD-MM-YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY A h:mm [vazta]",LLLL:"dddd, MMMM[achea] Do, YYYY, A h:mm [vazta]",llll:"ddd, D MMM YYYY, A h:mm [vazta]"},calendar:{sameDay:"[Aiz] LT",nextDay:"[Faleam] LT",nextWeek:"[Ieta to] dddd[,] LT",lastDay:"[Kal] LT",lastWeek:"[Fatlo] dddd[,] LT",sameElse:"L"},relativeTime:{future:"%s",past:"%s adim",s:t,ss:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}(er)/,ordinal:function(e,t){switch(t){case"D":return e+"er";default:case"M":case"Q":case"DDD":case"d":case"w":case"W":return e}},week:{dow:1,doy:4},meridiemParse:/rati|sokalli|donparam|sanje/,meridiemHour:function(e,t){return 12===e&&(e=0),"rati"===t?e<4?e:e+12:"sokalli"===t?e:"donparam"===t?e>12?e:e+12:"sanje"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"rati":e<12?"sokalli":e<16?"donparam":e<20?"sanje":"rati"}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"૧",2:"૨",3:"૩",4:"૪",5:"૫",6:"૬",7:"૭",8:"૮",9:"૯",0:"૦"},n={"૧":"1","૨":"2","૩":"3","૪":"4","૫":"5","૬":"6","૭":"7","૮":"8","૯":"9","૦":"0"};e.defineLocale("gu",{months:"જાન્યુઆરી_ફેબ્રુઆરી_માર્ચ_એપ્રિલ_મે_જૂન_જુલાઈ_ઑગસ્ટ_સપ્ટેમ્બર_ઑક્ટ્બર_નવેમ્બર_ડિસેમ્બર".split("_"),monthsShort:"જાન્યુ._ફેબ્રુ._માર્ચ_એપ્રિ._મે_જૂન_જુલા._ઑગ._સપ્ટે._ઑક્ટ્._નવે._ડિસે.".split("_"),monthsParseExact:!0,weekdays:"રવિવાર_સોમવાર_મંગળવાર_બુધ્વાર_ગુરુવાર_શુક્રવાર_શનિવાર".split("_"),weekdaysShort:"રવિ_સોમ_મંગળ_બુધ્_ગુરુ_શુક્ર_શનિ".split("_"),weekdaysMin:"ર_સો_મં_બુ_ગુ_શુ_શ".split("_"),longDateFormat:{LT:"A h:mm વાગ્યે",LTS:"A h:mm:ss વાગ્યે",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm વાગ્યે",LLLL:"dddd, D MMMM YYYY, A h:mm વાગ્યે"},calendar:{sameDay:"[આજ] LT",nextDay:"[કાલે] LT",nextWeek:"dddd, LT",lastDay:"[ગઇકાલે] LT",lastWeek:"[પાછલા] dddd, LT",sameElse:"L"},relativeTime:{future:"%s મા",past:"%s પેહલા",s:"અમુક પળો",ss:"%d સેકંડ",m:"એક મિનિટ",mm:"%d મિનિટ",h:"એક કલાક",hh:"%d કલાક",d:"એક દિવસ",dd:"%d દિવસ",M:"એક મહિનો",MM:"%d મહિનો",y:"એક વર્ષ",yy:"%d વર્ષ"},preparse:function(e){return e.replace(/[૧૨૩૪૫૬૭૮૯૦]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/રાત|બપોર|સવાર|સાંજ/,meridiemHour:function(e,t){return 12===e&&(e=0),"રાત"===t?e<4?e:e+12:"સવાર"===t?e:"બપોર"===t?e>=10?e:e+12:"સાંજ"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"રાત":e<10?"સવાર":e<17?"બપોર":e<20?"સાંજ":"રાત"},week:{dow:0,doy:6}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("he",{months:"ינואר_פברואר_מרץ_אפריל_מאי_יוני_יולי_אוגוסט_ספטמבר_אוקטובר_נובמבר_דצמבר".split("_"),monthsShort:"ינו׳_פבר׳_מרץ_אפר׳_מאי_יוני_יולי_אוג׳_ספט׳_אוק׳_נוב׳_דצמ׳".split("_"),weekdays:"ראשון_שני_שלישי_רביעי_חמישי_שישי_שבת".split("_"),weekdaysShort:"א׳_ב׳_ג׳_ד׳_ה׳_ו׳_ש׳".split("_"),weekdaysMin:"א_ב_ג_ד_ה_ו_ש".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [ב]MMMM YYYY",LLL:"D [ב]MMMM YYYY HH:mm",LLLL:"dddd, D [ב]MMMM YYYY HH:mm",l:"D/M/YYYY",ll:"D MMM YYYY",lll:"D MMM YYYY HH:mm",llll:"ddd, D MMM YYYY HH:mm"},calendar:{sameDay:"[היום ב־]LT",nextDay:"[מחר ב־]LT",nextWeek:"dddd [בשעה] LT",lastDay:"[אתמול ב־]LT",lastWeek:"[ביום] dddd [האחרון בשעה] LT",sameElse:"L"},relativeTime:{future:"בעוד %s",past:"לפני %s",s:"מספר שניות",ss:"%d שניות",m:"דקה",mm:"%d דקות",h:"שעה",hh:function(e){return 2===e?"שעתיים":e+" שעות"},d:"יום",dd:function(e){return 2===e?"יומיים":e+" ימים"},M:"חודש",MM:function(e){return 2===e?"חודשיים":e+" חודשים"},y:"שנה",yy:function(e){return 2===e?"שנתיים":e%10==0&&10!==e?e+" שנה":e+" שנים"}},meridiemParse:/אחה"צ|לפנה"צ|אחרי הצהריים|לפני הצהריים|לפנות בוקר|בבוקר|בערב/i,isPM:function(e){return/^(אחה"צ|אחרי הצהריים|בערב)$/.test(e)},meridiem:function(e,t,n){return e<5?"לפנות בוקר":e<10?"בבוקר":e<12?n?'לפנה"צ':"לפני הצהריים":e<18?n?'אחה"צ':"אחרי הצהריים":"בערב"}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"१",2:"२",3:"३",4:"४",5:"५",6:"६",7:"७",8:"८",9:"९",0:"०"},n={"१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9","०":"0"};e.defineLocale("hi",{months:"जनवरी_फ़रवरी_मार्च_अप्रैल_मई_जून_जुलाई_अगस्त_सितम्बर_अक्टूबर_नवम्बर_दिसम्बर".split("_"),monthsShort:"जन._फ़र._मार्च_अप्रै._मई_जून_जुल._अग._सित._अक्टू._नव._दिस.".split("_"),monthsParseExact:!0,weekdays:"रविवार_सोमवार_मंगलवार_बुधवार_गुरूवार_शुक्रवार_शनिवार".split("_"),weekdaysShort:"रवि_सोम_मंगल_बुध_गुरू_शुक्र_शनि".split("_"),weekdaysMin:"र_सो_मं_बु_गु_शु_श".split("_"),longDateFormat:{LT:"A h:mm बजे",LTS:"A h:mm:ss बजे",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm बजे",LLLL:"dddd, D MMMM YYYY, A h:mm बजे"},calendar:{sameDay:"[आज] LT",nextDay:"[कल] LT",nextWeek:"dddd, LT",lastDay:"[कल] LT",lastWeek:"[पिछले] dddd, LT",sameElse:"L"},relativeTime:{future:"%s में",past:"%s पहले",s:"कुछ ही क्षण",ss:"%d सेकंड",m:"एक मिनट",mm:"%d मिनट",h:"एक घंटा",hh:"%d घंटे",d:"एक दिन",dd:"%d दिन",M:"एक महीने",MM:"%d महीने",y:"एक वर्ष",yy:"%d वर्ष"},preparse:function(e){return e.replace(/[१२३४५६७८९०]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/रात|सुबह|दोपहर|शाम/,meridiemHour:function(e,t){return 12===e&&(e=0),"रात"===t?e<4?e:e+12:"सुबह"===t?e:"दोपहर"===t?e>=10?e:e+12:"शाम"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"रात":e<10?"सुबह":e<17?"दोपहर":e<20?"शाम":"रात"},week:{dow:0,doy:6}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n){var r=e+" ";switch(n){case"ss":return r+=1===e?"sekunda":2===e||3===e||4===e?"sekunde":"sekundi";case"m":return t?"jedna minuta":"jedne minute";case"mm":return r+=1===e?"minuta":2===e||3===e||4===e?"minute":"minuta";case"h":return t?"jedan sat":"jednog sata";case"hh":return r+=1===e?"sat":2===e||3===e||4===e?"sata":"sati";case"dd":return r+=1===e?"dan":"dana";case"MM":return r+=1===e?"mjesec":2===e||3===e||4===e?"mjeseca":"mjeseci";case"yy":return r+=1===e?"godina":2===e||3===e||4===e?"godine":"godina"}}e.defineLocale("hr",{months:{format:"siječnja_veljače_ožujka_travnja_svibnja_lipnja_srpnja_kolovoza_rujna_listopada_studenoga_prosinca".split("_"),standalone:"siječanj_veljača_ožujak_travanj_svibanj_lipanj_srpanj_kolovoz_rujan_listopad_studeni_prosinac".split("_")},monthsShort:"sij._velj._ožu._tra._svi._lip._srp._kol._ruj._lis._stu._pro.".split("_"),monthsParseExact:!0,weekdays:"nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sri._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd, D. MMMM YYYY H:mm"},calendar:{sameDay:"[danas u] LT",nextDay:"[sutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedjelju] [u] LT";case 3:return"[u] [srijedu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[jučer u] LT",lastWeek:function(){switch(this.day()){case 0:case 3:return"[prošlu] dddd [u] LT";case 6:return"[prošle] [subote] [u] LT";case 1:case 2:case 4:case 5:return"[prošli] dddd [u] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"prije %s",s:"par sekundi",ss:t,m:t,mm:t,h:t,hh:t,d:"dan",dd:t,M:"mjesec",MM:t,y:"godinu",yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";var t="vasárnap hétfőn kedden szerdán csütörtökön pénteken szombaton".split(" ");function n(e,t,n,r){var a=e;switch(n){case"s":return r||t?"néhány másodperc":"néhány másodperce";case"ss":return a+(r||t)?" másodperc":" másodperce";case"m":return"egy"+(r||t?" perc":" perce");case"mm":return a+(r||t?" perc":" perce");case"h":return"egy"+(r||t?" óra":" órája");case"hh":return a+(r||t?" óra":" órája");case"d":return"egy"+(r||t?" nap":" napja");case"dd":return a+(r||t?" nap":" napja");case"M":return"egy"+(r||t?" hónap":" hónapja");case"MM":return a+(r||t?" hónap":" hónapja");case"y":return"egy"+(r||t?" év":" éve");case"yy":return a+(r||t?" év":" éve")}return""}function r(e){return(e?"":"[múlt] ")+"["+t[this.day()]+"] LT[-kor]"}e.defineLocale("hu",{months:"január_február_március_április_május_június_július_augusztus_szeptember_október_november_december".split("_"),monthsShort:"jan_feb_márc_ápr_máj_jún_júl_aug_szept_okt_nov_dec".split("_"),weekdays:"vasárnap_hétfő_kedd_szerda_csütörtök_péntek_szombat".split("_"),weekdaysShort:"vas_hét_kedd_sze_csüt_pén_szo".split("_"),weekdaysMin:"v_h_k_sze_cs_p_szo".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"YYYY.MM.DD.",LL:"YYYY. MMMM D.",LLL:"YYYY. MMMM D. H:mm",LLLL:"YYYY. MMMM D., dddd H:mm"},meridiemParse:/de|du/i,isPM:function(e){return"u"===e.charAt(1).toLowerCase()},meridiem:function(e,t,n){return e<12?!0===n?"de":"DE":!0===n?"du":"DU"},calendar:{sameDay:"[ma] LT[-kor]",nextDay:"[holnap] LT[-kor]",nextWeek:function(){return r.call(this,!0)},lastDay:"[tegnap] LT[-kor]",lastWeek:function(){return r.call(this,!1)},sameElse:"L"},relativeTime:{future:"%s múlva",past:"%s",s:n,ss:n,m:n,mm:n,h:n,hh:n,d:n,dd:n,M:n,MM:n,y:n,yy:n},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("hy-am",{months:{format:"հունվարի_փետրվարի_մարտի_ապրիլի_մայիսի_հունիսի_հուլիսի_օգոստոսի_սեպտեմբերի_հոկտեմբերի_նոյեմբերի_դեկտեմբերի".split("_"),standalone:"հունվար_փետրվար_մարտ_ապրիլ_մայիս_հունիս_հուլիս_օգոստոս_սեպտեմբեր_հոկտեմբեր_նոյեմբեր_դեկտեմբեր".split("_")},monthsShort:"հնվ_փտր_մրտ_ապր_մյս_հնս_հլս_օգս_սպտ_հկտ_նմբ_դկտ".split("_"),weekdays:"կիրակի_երկուշաբթի_երեքշաբթի_չորեքշաբթի_հինգշաբթի_ուրբաթ_շաբաթ".split("_"),weekdaysShort:"կրկ_երկ_երք_չրք_հնգ_ուրբ_շբթ".split("_"),weekdaysMin:"կրկ_երկ_երք_չրք_հնգ_ուրբ_շբթ".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY թ.",LLL:"D MMMM YYYY թ., HH:mm",LLLL:"dddd, D MMMM YYYY թ., HH:mm"},calendar:{sameDay:"[այսօր] LT",nextDay:"[վաղը] LT",lastDay:"[երեկ] LT",nextWeek:function(){return"dddd [օրը ժամը] LT"},lastWeek:function(){return"[անցած] dddd [օրը ժամը] LT"},sameElse:"L"},relativeTime:{future:"%s հետո",past:"%s առաջ",s:"մի քանի վայրկյան",ss:"%d վայրկյան",m:"րոպե",mm:"%d րոպե",h:"ժամ",hh:"%d ժամ",d:"օր",dd:"%d օր",M:"ամիս",MM:"%d ամիս",y:"տարի",yy:"%d տարի"},meridiemParse:/գիշերվա|առավոտվա|ցերեկվա|երեկոյան/,isPM:function(e){return/^(ցերեկվա|երեկոյան)$/.test(e)},meridiem:function(e){return e<4?"գիշերվա":e<12?"առավոտվա":e<17?"ցերեկվա":"երեկոյան"},dayOfMonthOrdinalParse:/\d{1,2}|\d{1,2}-(ին|րդ)/,ordinal:function(e,t){switch(t){case"DDD":case"w":case"W":case"DDDo":return 1===e?e+"-ին":e+"-րդ";default:return e}},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("id",{months:"Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_November_Desember".split("_"),monthsShort:"Jan_Feb_Mar_Apr_Mei_Jun_Jul_Agt_Sep_Okt_Nov_Des".split("_"),weekdays:"Minggu_Senin_Selasa_Rabu_Kamis_Jumat_Sabtu".split("_"),weekdaysShort:"Min_Sen_Sel_Rab_Kam_Jum_Sab".split("_"),weekdaysMin:"Mg_Sn_Sl_Rb_Km_Jm_Sb".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},meridiemParse:/pagi|siang|sore|malam/,meridiemHour:function(e,t){return 12===e&&(e=0),"pagi"===t?e:"siang"===t?e>=11?e:e+12:"sore"===t||"malam"===t?e+12:void 0},meridiem:function(e,t,n){return e<11?"pagi":e<15?"siang":e<19?"sore":"malam"},calendar:{sameDay:"[Hari ini pukul] LT",nextDay:"[Besok pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kemarin pukul] LT",lastWeek:"dddd [lalu pukul] LT",sameElse:"L"},relativeTime:{future:"dalam %s",past:"%s yang lalu",s:"beberapa detik",ss:"%d detik",m:"semenit",mm:"%d menit",h:"sejam",hh:"%d jam",d:"sehari",dd:"%d hari",M:"sebulan",MM:"%d bulan",y:"setahun",yy:"%d tahun"},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e){return e%100==11||e%10!=1}function n(e,n,r,a){var o=e+" ";switch(r){case"s":return n||a?"nokkrar sekúndur":"nokkrum sekúndum";case"ss":return t(e)?o+(n||a?"sekúndur":"sekúndum"):o+"sekúnda";case"m":return n?"mínúta":"mínútu";case"mm":return t(e)?o+(n||a?"mínútur":"mínútum"):n?o+"mínúta":o+"mínútu";case"hh":return t(e)?o+(n||a?"klukkustundir":"klukkustundum"):o+"klukkustund";case"d":return n?"dagur":a?"dag":"degi";case"dd":return t(e)?n?o+"dagar":o+(a?"daga":"dögum"):n?o+"dagur":o+(a?"dag":"degi");case"M":return n?"mánuður":a?"mánuð":"mánuði";case"MM":return t(e)?n?o+"mánuðir":o+(a?"mánuði":"mánuðum"):n?o+"mánuður":o+(a?"mánuð":"mánuði");case"y":return n||a?"ár":"ári";case"yy":return t(e)?o+(n||a?"ár":"árum"):o+(n||a?"ár":"ári")}}e.defineLocale("is",{months:"janúar_febrúar_mars_apríl_maí_júní_júlí_ágúst_september_október_nóvember_desember".split("_"),monthsShort:"jan_feb_mar_apr_maí_jún_júl_ágú_sep_okt_nóv_des".split("_"),weekdays:"sunnudagur_mánudagur_þriðjudagur_miðvikudagur_fimmtudagur_föstudagur_laugardagur".split("_"),weekdaysShort:"sun_mán_þri_mið_fim_fös_lau".split("_"),weekdaysMin:"Su_Má_Þr_Mi_Fi_Fö_La".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY [kl.] H:mm",LLLL:"dddd, D. MMMM YYYY [kl.] H:mm"},calendar:{sameDay:"[í dag kl.] LT",nextDay:"[á morgun kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[í gær kl.] LT",lastWeek:"[síðasta] dddd [kl.] LT",sameElse:"L"},relativeTime:{future:"eftir %s",past:"fyrir %s síðan",s:n,ss:n,m:n,mm:n,h:"klukkustund",hh:n,d:n,dd:n,M:n,MM:n,y:n,yy:n},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("it",{months:"gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre".split("_"),monthsShort:"gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic".split("_"),weekdays:"domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato".split("_"),weekdaysShort:"dom_lun_mar_mer_gio_ven_sab".split("_"),weekdaysMin:"do_lu_ma_me_gi_ve_sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Oggi alle] LT",nextDay:"[Domani alle] LT",nextWeek:"dddd [alle] LT",lastDay:"[Ieri alle] LT",lastWeek:function(){switch(this.day()){case 0:return"[la scorsa] dddd [alle] LT";default:return"[lo scorso] dddd [alle] LT"}},sameElse:"L"},relativeTime:{future:function(e){return(/^[0-9].+$/.test(e)?"tra":"in")+" "+e},past:"%s fa",s:"alcuni secondi",ss:"%d secondi",m:"un minuto",mm:"%d minuti",h:"un'ora",hh:"%d ore",d:"un giorno",dd:"%d giorni",M:"un mese",MM:"%d mesi",y:"un anno",yy:"%d anni"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("it-ch",{months:"gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre".split("_"),monthsShort:"gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic".split("_"),weekdays:"domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato".split("_"),weekdaysShort:"dom_lun_mar_mer_gio_ven_sab".split("_"),weekdaysMin:"do_lu_ma_me_gi_ve_sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Oggi alle] LT",nextDay:"[Domani alle] LT",nextWeek:"dddd [alle] LT",lastDay:"[Ieri alle] LT",lastWeek:function(){switch(this.day()){case 0:return"[la scorsa] dddd [alle] LT";default:return"[lo scorso] dddd [alle] LT"}},sameElse:"L"},relativeTime:{future:function(e){return(/^[0-9].+$/.test(e)?"tra":"in")+" "+e},past:"%s fa",s:"alcuni secondi",ss:"%d secondi",m:"un minuto",mm:"%d minuti",h:"un'ora",hh:"%d ore",d:"un giorno",dd:"%d giorni",M:"un mese",MM:"%d mesi",y:"un anno",yy:"%d anni"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ja",{months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"日曜日_月曜日_火曜日_水曜日_木曜日_金曜日_土曜日".split("_"),weekdaysShort:"日_月_火_水_木_金_土".split("_"),weekdaysMin:"日_月_火_水_木_金_土".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY/MM/DD",LL:"YYYY年M月D日",LLL:"YYYY年M月D日 HH:mm",LLLL:"YYYY年M月D日 dddd HH:mm",l:"YYYY/MM/DD",ll:"YYYY年M月D日",lll:"YYYY年M月D日 HH:mm",llll:"YYYY年M月D日(ddd) HH:mm"},meridiemParse:/午前|午後/i,isPM:function(e){return"午後"===e},meridiem:function(e,t,n){return e<12?"午前":"午後"},calendar:{sameDay:"[今日] LT",nextDay:"[明日] LT",nextWeek:function(e){return e.week()<this.week()?"[来週]dddd LT":"dddd LT"},lastDay:"[昨日] LT",lastWeek:function(e){return this.week()<e.week()?"[先週]dddd LT":"dddd LT"},sameElse:"L"},dayOfMonthOrdinalParse:/\d{1,2}日/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"日";default:return e}},relativeTime:{future:"%s後",past:"%s前",s:"数秒",ss:"%d秒",m:"1分",mm:"%d分",h:"1時間",hh:"%d時間",d:"1日",dd:"%d日",M:"1ヶ月",MM:"%dヶ月",y:"1年",yy:"%d年"}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("jv",{months:"Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_Nopember_Desember".split("_"),monthsShort:"Jan_Feb_Mar_Apr_Mei_Jun_Jul_Ags_Sep_Okt_Nop_Des".split("_"),weekdays:"Minggu_Senen_Seloso_Rebu_Kemis_Jemuwah_Septu".split("_"),weekdaysShort:"Min_Sen_Sel_Reb_Kem_Jem_Sep".split("_"),weekdaysMin:"Mg_Sn_Sl_Rb_Km_Jm_Sp".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},meridiemParse:/enjing|siyang|sonten|ndalu/,meridiemHour:function(e,t){return 12===e&&(e=0),"enjing"===t?e:"siyang"===t?e>=11?e:e+12:"sonten"===t||"ndalu"===t?e+12:void 0},meridiem:function(e,t,n){return e<11?"enjing":e<15?"siyang":e<19?"sonten":"ndalu"},calendar:{sameDay:"[Dinten puniko pukul] LT",nextDay:"[Mbenjang pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kala wingi pukul] LT",lastWeek:"dddd [kepengker pukul] LT",sameElse:"L"},relativeTime:{future:"wonten ing %s",past:"%s ingkang kepengker",s:"sawetawis detik",ss:"%d detik",m:"setunggal menit",mm:"%d menit",h:"setunggal jam",hh:"%d jam",d:"sedinten",dd:"%d dinten",M:"sewulan",MM:"%d wulan",y:"setaun",yy:"%d taun"},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ka",{months:{standalone:"იანვარი_თებერვალი_მარტი_აპრილი_მაისი_ივნისი_ივლისი_აგვისტო_სექტემბერი_ოქტომბერი_ნოემბერი_დეკემბერი".split("_"),format:"იანვარს_თებერვალს_მარტს_აპრილის_მაისს_ივნისს_ივლისს_აგვისტს_სექტემბერს_ოქტომბერს_ნოემბერს_დეკემბერს".split("_")},monthsShort:"იან_თებ_მარ_აპრ_მაი_ივნ_ივლ_აგვ_სექ_ოქტ_ნოე_დეკ".split("_"),weekdays:{standalone:"კვირა_ორშაბათი_სამშაბათი_ოთხშაბათი_ხუთშაბათი_პარასკევი_შაბათი".split("_"),format:"კვირას_ორშაბათს_სამშაბათს_ოთხშაბათს_ხუთშაბათს_პარასკევს_შაბათს".split("_"),isFormat:/(წინა|შემდეგ)/},weekdaysShort:"კვი_ორშ_სამ_ოთხ_ხუთ_პარ_შაბ".split("_"),weekdaysMin:"კვ_ორ_სა_ოთ_ხუ_პა_შა".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[დღეს] LT[-ზე]",nextDay:"[ხვალ] LT[-ზე]",lastDay:"[გუშინ] LT[-ზე]",nextWeek:"[შემდეგ] dddd LT[-ზე]",lastWeek:"[წინა] dddd LT-ზე",sameElse:"L"},relativeTime:{future:function(e){return/(წამი|წუთი|საათი|წელი)/.test(e)?e.replace(/ი$/,"ში"):e+"ში"},past:function(e){return/(წამი|წუთი|საათი|დღე|თვე)/.test(e)?e.replace(/(ი|ე)$/,"ის წინ"):/წელი/.test(e)?e.replace(/წელი$/,"წლის წინ"):void 0},s:"რამდენიმე წამი",ss:"%d წამი",m:"წუთი",mm:"%d წუთი",h:"საათი",hh:"%d საათი",d:"დღე",dd:"%d დღე",M:"თვე",MM:"%d თვე",y:"წელი",yy:"%d წელი"},dayOfMonthOrdinalParse:/0|1-ლი|მე-\d{1,2}|\d{1,2}-ე/,ordinal:function(e){return 0===e?e:1===e?e+"-ლი":e<20||e<=100&&e%20==0||e%100==0?"მე-"+e:e+"-ე"},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={0:"-ші",1:"-ші",2:"-ші",3:"-ші",4:"-ші",5:"-ші",6:"-шы",7:"-ші",8:"-ші",9:"-шы",10:"-шы",20:"-шы",30:"-шы",40:"-шы",50:"-ші",60:"-шы",70:"-ші",80:"-ші",90:"-шы",100:"-ші"};e.defineLocale("kk",{months:"қаңтар_ақпан_наурыз_сәуір_мамыр_маусым_шілде_тамыз_қыркүйек_қазан_қараша_желтоқсан".split("_"),monthsShort:"қаң_ақп_нау_сәу_мам_мау_шіл_там_қыр_қаз_қар_жел".split("_"),weekdays:"жексенбі_дүйсенбі_сейсенбі_сәрсенбі_бейсенбі_жұма_сенбі".split("_"),weekdaysShort:"жек_дүй_сей_сәр_бей_жұм_сен".split("_"),weekdaysMin:"жк_дй_сй_ср_бй_жм_сн".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Бүгін сағат] LT",nextDay:"[Ертең сағат] LT",nextWeek:"dddd [сағат] LT",lastDay:"[Кеше сағат] LT",lastWeek:"[Өткен аптаның] dddd [сағат] LT",sameElse:"L"},relativeTime:{future:"%s ішінде",past:"%s бұрын",s:"бірнеше секунд",ss:"%d секунд",m:"бір минут",mm:"%d минут",h:"бір сағат",hh:"%d сағат",d:"бір күн",dd:"%d күн",M:"бір ай",MM:"%d ай",y:"бір жыл",yy:"%d жыл"},dayOfMonthOrdinalParse:/\d{1,2}-(ші|шы)/,ordinal:function(e){var n=e%10,r=e>=100?100:null;return e+(t[e]||t[n]||t[r])},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"១",2:"២",3:"៣",4:"៤",5:"៥",6:"៦",7:"៧",8:"៨",9:"៩",0:"០"},n={"១":"1","២":"2","៣":"3","៤":"4","៥":"5","៦":"6","៧":"7","៨":"8","៩":"9","០":"0"};e.defineLocale("km",{months:"មករា_កុម្ភៈ_មីនា_មេសា_ឧសភា_មិថុនា_កក្កដា_សីហា_កញ្ញា_តុលា_វិច្ឆិកា_ធ្នូ".split("_"),monthsShort:"មករា_កុម្ភៈ_មីនា_មេសា_ឧសភា_មិថុនា_កក្កដា_សីហា_កញ្ញា_តុលា_វិច្ឆិកា_ធ្នូ".split("_"),weekdays:"អាទិត្យ_ច័ន្ទ_អង្គារ_ពុធ_ព្រហស្បតិ៍_សុក្រ_សៅរ៍".split("_"),weekdaysShort:"អា_ច_អ_ព_ព្រ_សុ_ស".split("_"),weekdaysMin:"អា_ច_អ_ព_ព្រ_សុ_ស".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},meridiemParse:/ព្រឹក|ល្ងាច/,isPM:function(e){return"ល្ងាច"===e},meridiem:function(e,t,n){return e<12?"ព្រឹក":"ល្ងាច"},calendar:{sameDay:"[ថ្ងៃនេះ ម៉ោង] LT",nextDay:"[ស្អែក ម៉ោង] LT",nextWeek:"dddd [ម៉ោង] LT",lastDay:"[ម្សិលមិញ ម៉ោង] LT",lastWeek:"dddd [សប្តាហ៍មុន] [ម៉ោង] LT",sameElse:"L"},relativeTime:{future:"%sទៀត",past:"%sមុន",s:"ប៉ុន្មានវិនាទី",ss:"%d វិនាទី",m:"មួយនាទី",mm:"%d នាទី",h:"មួយម៉ោង",hh:"%d ម៉ោង",d:"មួយថ្ងៃ",dd:"%d ថ្ងៃ",M:"មួយខែ",MM:"%d ខែ",y:"មួយឆ្នាំ",yy:"%d ឆ្នាំ"},dayOfMonthOrdinalParse:/ទី\d{1,2}/,ordinal:"ទី%d",preparse:function(e){return e.replace(/[១២៣៤៥៦៧៨៩០]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"೧",2:"೨",3:"೩",4:"೪",5:"೫",6:"೬",7:"೭",8:"೮",9:"೯",0:"೦"},n={"೧":"1","೨":"2","೩":"3","೪":"4","೫":"5","೬":"6","೭":"7","೮":"8","೯":"9","೦":"0"};e.defineLocale("kn",{months:"ಜನವರಿ_ಫೆಬ್ರವರಿ_ಮಾರ್ಚ್_ಏಪ್ರಿಲ್_ಮೇ_ಜೂನ್_ಜುಲೈ_ಆಗಸ್ಟ್_ಸೆಪ್ಟೆಂಬರ್_ಅಕ್ಟೋಬರ್_ನವೆಂಬರ್_ಡಿಸೆಂಬರ್".split("_"),monthsShort:"ಜನ_ಫೆಬ್ರ_ಮಾರ್ಚ್_ಏಪ್ರಿಲ್_ಮೇ_ಜೂನ್_ಜುಲೈ_ಆಗಸ್ಟ್_ಸೆಪ್ಟೆಂ_ಅಕ್ಟೋ_ನವೆಂ_ಡಿಸೆಂ".split("_"),monthsParseExact:!0,weekdays:"ಭಾನುವಾರ_ಸೋಮವಾರ_ಮಂಗಳವಾರ_ಬುಧವಾರ_ಗುರುವಾರ_ಶುಕ್ರವಾರ_ಶನಿವಾರ".split("_"),weekdaysShort:"ಭಾನು_ಸೋಮ_ಮಂಗಳ_ಬುಧ_ಗುರು_ಶುಕ್ರ_ಶನಿ".split("_"),weekdaysMin:"ಭಾ_ಸೋ_ಮಂ_ಬು_ಗು_ಶು_ಶ".split("_"),longDateFormat:{LT:"A h:mm",LTS:"A h:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm",LLLL:"dddd, D MMMM YYYY, A h:mm"},calendar:{sameDay:"[ಇಂದು] LT",nextDay:"[ನಾಳೆ] LT",nextWeek:"dddd, LT",lastDay:"[ನಿನ್ನೆ] LT",lastWeek:"[ಕೊನೆಯ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s ನಂತರ",past:"%s ಹಿಂದೆ",s:"ಕೆಲವು ಕ್ಷಣಗಳು",ss:"%d ಸೆಕೆಂಡುಗಳು",m:"ಒಂದು ನಿಮಿಷ",mm:"%d ನಿಮಿಷ",h:"ಒಂದು ಗಂಟೆ",hh:"%d ಗಂಟೆ",d:"ಒಂದು ದಿನ",dd:"%d ದಿನ",M:"ಒಂದು ತಿಂಗಳು",MM:"%d ತಿಂಗಳು",y:"ಒಂದು ವರ್ಷ",yy:"%d ವರ್ಷ"},preparse:function(e){return e.replace(/[೧೨೩೪೫೬೭೮೯೦]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/ರಾತ್ರಿ|ಬೆಳಿಗ್ಗೆ|ಮಧ್ಯಾಹ್ನ|ಸಂಜೆ/,meridiemHour:function(e,t){return 12===e&&(e=0),"ರಾತ್ರಿ"===t?e<4?e:e+12:"ಬೆಳಿಗ್ಗೆ"===t?e:"ಮಧ್ಯಾಹ್ನ"===t?e>=10?e:e+12:"ಸಂಜೆ"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"ರಾತ್ರಿ":e<10?"ಬೆಳಿಗ್ಗೆ":e<17?"ಮಧ್ಯಾಹ್ನ":e<20?"ಸಂಜೆ":"ರಾತ್ರಿ"},dayOfMonthOrdinalParse:/\d{1,2}(ನೇ)/,ordinal:function(e){return e+"ನೇ"},week:{dow:0,doy:6}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ko",{months:"1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월".split("_"),monthsShort:"1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월".split("_"),weekdays:"일요일_월요일_화요일_수요일_목요일_금요일_토요일".split("_"),weekdaysShort:"일_월_화_수_목_금_토".split("_"),weekdaysMin:"일_월_화_수_목_금_토".split("_"),longDateFormat:{LT:"A h:mm",LTS:"A h:mm:ss",L:"YYYY.MM.DD.",LL:"YYYY년 MMMM D일",LLL:"YYYY년 MMMM D일 A h:mm",LLLL:"YYYY년 MMMM D일 dddd A h:mm",l:"YYYY.MM.DD.",ll:"YYYY년 MMMM D일",lll:"YYYY년 MMMM D일 A h:mm",llll:"YYYY년 MMMM D일 dddd A h:mm"},calendar:{sameDay:"오늘 LT",nextDay:"내일 LT",nextWeek:"dddd LT",lastDay:"어제 LT",lastWeek:"지난주 dddd LT",sameElse:"L"},relativeTime:{future:"%s 후",past:"%s 전",s:"몇 초",ss:"%d초",m:"1분",mm:"%d분",h:"한 시간",hh:"%d시간",d:"하루",dd:"%d일",M:"한 달",MM:"%d달",y:"일 년",yy:"%d년"},dayOfMonthOrdinalParse:/\d{1,2}(일|월|주)/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"일";case"M":return e+"월";case"w":case"W":return e+"주";default:return e}},meridiemParse:/오전|오후/,isPM:function(e){return"오후"===e},meridiem:function(e,t,n){return e<12?"오전":"오후"}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩",0:"٠"},n={"١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","٠":"0"},r=["کانونی دووەم","شوبات","ئازار","نیسان","ئایار","حوزەیران","تەمموز","ئاب","ئەیلوول","تشرینی یەكەم","تشرینی دووەم","كانونی یەکەم"];e.defineLocale("ku",{months:r,monthsShort:r,weekdays:"یه‌كشه‌ممه‌_دووشه‌ممه‌_سێشه‌ممه‌_چوارشه‌ممه‌_پێنجشه‌ممه‌_هه‌ینی_شه‌ممه‌".split("_"),weekdaysShort:"یه‌كشه‌م_دووشه‌م_سێشه‌م_چوارشه‌م_پێنجشه‌م_هه‌ینی_شه‌ممه‌".split("_"),weekdaysMin:"ی_د_س_چ_پ_ه_ش".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},meridiemParse:/ئێواره‌|به‌یانی/,isPM:function(e){return/ئێواره‌/.test(e)},meridiem:function(e,t,n){return e<12?"به‌یانی":"ئێواره‌"},calendar:{sameDay:"[ئه‌مرۆ كاتژمێر] LT",nextDay:"[به‌یانی كاتژمێر] LT",nextWeek:"dddd [كاتژمێر] LT",lastDay:"[دوێنێ كاتژمێر] LT",lastWeek:"dddd [كاتژمێر] LT",sameElse:"L"},relativeTime:{future:"له‌ %s",past:"%s",s:"چه‌ند چركه‌یه‌ك",ss:"چركه‌ %d",m:"یه‌ك خوله‌ك",mm:"%d خوله‌ك",h:"یه‌ك كاتژمێر",hh:"%d كاتژمێر",d:"یه‌ك ڕۆژ",dd:"%d ڕۆژ",M:"یه‌ك مانگ",MM:"%d مانگ",y:"یه‌ك ساڵ",yy:"%d ساڵ"},preparse:function(e){return e.replace(/[١٢٣٤٥٦٧٨٩٠]/g,function(e){return n[e]}).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]}).replace(/,/g,"،")},week:{dow:6,doy:12}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={0:"-чү",1:"-чи",2:"-чи",3:"-чү",4:"-чү",5:"-чи",6:"-чы",7:"-чи",8:"-чи",9:"-чу",10:"-чу",20:"-чы",30:"-чу",40:"-чы",50:"-чү",60:"-чы",70:"-чи",80:"-чи",90:"-чу",100:"-чү"};e.defineLocale("ky",{months:"январь_февраль_март_апрель_май_июнь_июль_август_сентябрь_октябрь_ноябрь_декабрь".split("_"),monthsShort:"янв_фев_март_апр_май_июнь_июль_авг_сен_окт_ноя_дек".split("_"),weekdays:"Жекшемби_Дүйшөмбү_Шейшемби_Шаршемби_Бейшемби_Жума_Ишемби".split("_"),weekdaysShort:"Жек_Дүй_Шей_Шар_Бей_Жум_Ише".split("_"),weekdaysMin:"Жк_Дй_Шй_Шр_Бй_Жм_Иш".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Бүгүн саат] LT",nextDay:"[Эртең саат] LT",nextWeek:"dddd [саат] LT",lastDay:"[Кечээ саат] LT",lastWeek:"[Өткөн аптанын] dddd [күнү] [саат] LT",sameElse:"L"},relativeTime:{future:"%s ичинде",past:"%s мурун",s:"бирнече секунд",ss:"%d секунд",m:"бир мүнөт",mm:"%d мүнөт",h:"бир саат",hh:"%d саат",d:"бир күн",dd:"%d күн",M:"бир ай",MM:"%d ай",y:"бир жыл",yy:"%d жыл"},dayOfMonthOrdinalParse:/\d{1,2}-(чи|чы|чү|чу)/,ordinal:function(e){var n=e%10,r=e>=100?100:null;return e+(t[e]||t[n]||t[r])},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n,r){var a={m:["eng Minutt","enger Minutt"],h:["eng Stonn","enger Stonn"],d:["een Dag","engem Dag"],M:["ee Mount","engem Mount"],y:["ee Joer","engem Joer"]};return t?a[n][0]:a[n][1]}function n(e){if(e=parseInt(e,10),isNaN(e))return!1;if(e<0)return!0;if(e<10)return 4<=e&&e<=7;if(e<100){var t=e%10,r=e/10;return n(0===t?r:t)}if(e<1e4){for(;e>=10;)e/=10;return n(e)}return n(e/=1e3)}e.defineLocale("lb",{months:"Januar_Februar_Mäerz_Abrëll_Mee_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Febr._Mrz._Abr._Mee_Jun._Jul._Aug._Sept._Okt._Nov._Dez.".split("_"),monthsParseExact:!0,weekdays:"Sonndeg_Méindeg_Dënschdeg_Mëttwoch_Donneschdeg_Freideg_Samschdeg".split("_"),weekdaysShort:"So._Mé._Dë._Më._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mé_Dë_Më_Do_Fr_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm [Auer]",LTS:"H:mm:ss [Auer]",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm [Auer]",LLLL:"dddd, D. MMMM YYYY H:mm [Auer]"},calendar:{sameDay:"[Haut um] LT",sameElse:"L",nextDay:"[Muer um] LT",nextWeek:"dddd [um] LT",lastDay:"[Gëschter um] LT",lastWeek:function(){switch(this.day()){case 2:case 4:return"[Leschten] dddd [um] LT";default:return"[Leschte] dddd [um] LT"}}},relativeTime:{future:function(e){return n(e.substr(0,e.indexOf(" ")))?"a "+e:"an "+e},past:function(e){return n(e.substr(0,e.indexOf(" ")))?"viru "+e:"virun "+e},s:"e puer Sekonnen",ss:"%d Sekonnen",m:t,mm:"%d Minutten",h:t,hh:"%d Stonnen",d:t,dd:"%d Deeg",M:t,MM:"%d Méint",y:t,yy:"%d Joer"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("lo",{months:"ມັງກອນ_ກຸມພາ_ມີນາ_ເມສາ_ພຶດສະພາ_ມິຖຸນາ_ກໍລະກົດ_ສິງຫາ_ກັນຍາ_ຕຸລາ_ພະຈິກ_ທັນວາ".split("_"),monthsShort:"ມັງກອນ_ກຸມພາ_ມີນາ_ເມສາ_ພຶດສະພາ_ມິຖຸນາ_ກໍລະກົດ_ສິງຫາ_ກັນຍາ_ຕຸລາ_ພະຈິກ_ທັນວາ".split("_"),weekdays:"ອາທິດ_ຈັນ_ອັງຄານ_ພຸດ_ພະຫັດ_ສຸກ_ເສົາ".split("_"),weekdaysShort:"ທິດ_ຈັນ_ອັງຄານ_ພຸດ_ພະຫັດ_ສຸກ_ເສົາ".split("_"),weekdaysMin:"ທ_ຈ_ອຄ_ພ_ພຫ_ສກ_ສ".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"ວັນdddd D MMMM YYYY HH:mm"},meridiemParse:/ຕອນເຊົ້າ|ຕອນແລງ/,isPM:function(e){return"ຕອນແລງ"===e},meridiem:function(e,t,n){return e<12?"ຕອນເຊົ້າ":"ຕອນແລງ"},calendar:{sameDay:"[ມື້ນີ້ເວລາ] LT",nextDay:"[ມື້ອື່ນເວລາ] LT",nextWeek:"[ວັນ]dddd[ໜ້າເວລາ] LT",lastDay:"[ມື້ວານນີ້ເວລາ] LT",lastWeek:"[ວັນ]dddd[ແລ້ວນີ້ເວລາ] LT",sameElse:"L"},relativeTime:{future:"ອີກ %s",past:"%sຜ່ານມາ",s:"ບໍ່ເທົ່າໃດວິນາທີ",ss:"%d ວິນາທີ",m:"1 ນາທີ",mm:"%d ນາທີ",h:"1 ຊົ່ວໂມງ",hh:"%d ຊົ່ວໂມງ",d:"1 ມື້",dd:"%d ມື້",M:"1 ເດືອນ",MM:"%d ເດືອນ",y:"1 ປີ",yy:"%d ປີ"},dayOfMonthOrdinalParse:/(ທີ່)\d{1,2}/,ordinal:function(e){return"ທີ່"+e}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={ss:"sekundė_sekundžių_sekundes",m:"minutė_minutės_minutę",mm:"minutės_minučių_minutes",h:"valanda_valandos_valandą",hh:"valandos_valandų_valandas",d:"diena_dienos_dieną",dd:"dienos_dienų_dienas",M:"mėnuo_mėnesio_mėnesį",MM:"mėnesiai_mėnesių_mėnesius",y:"metai_metų_metus",yy:"metai_metų_metus"};function n(e,t,n,r){return t?a(n)[0]:r?a(n)[1]:a(n)[2]}function r(e){return e%10==0||e>10&&e<20}function a(e){return t[e].split("_")}function o(e,t,o,i){var s=e+" ";return 1===e?s+n(0,t,o[0],i):t?s+(r(e)?a(o)[1]:a(o)[0]):i?s+a(o)[1]:s+(r(e)?a(o)[1]:a(o)[2])}e.defineLocale("lt",{months:{format:"sausio_vasario_kovo_balandžio_gegužės_birželio_liepos_rugpjūčio_rugsėjo_spalio_lapkričio_gruodžio".split("_"),standalone:"sausis_vasaris_kovas_balandis_gegužė_birželis_liepa_rugpjūtis_rugsėjis_spalis_lapkritis_gruodis".split("_"),isFormat:/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?|MMMM?(\[[^\[\]]*\]|\s)+D[oD]?/},monthsShort:"sau_vas_kov_bal_geg_bir_lie_rgp_rgs_spa_lap_grd".split("_"),weekdays:{format:"sekmadienį_pirmadienį_antradienį_trečiadienį_ketvirtadienį_penktadienį_šeštadienį".split("_"),standalone:"sekmadienis_pirmadienis_antradienis_trečiadienis_ketvirtadienis_penktadienis_šeštadienis".split("_"),isFormat:/dddd HH:mm/},weekdaysShort:"Sek_Pir_Ant_Tre_Ket_Pen_Šeš".split("_"),weekdaysMin:"S_P_A_T_K_Pn_Š".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"YYYY [m.] MMMM D [d.]",LLL:"YYYY [m.] MMMM D [d.], HH:mm [val.]",LLLL:"YYYY [m.] MMMM D [d.], dddd, HH:mm [val.]",l:"YYYY-MM-DD",ll:"YYYY [m.] MMMM D [d.]",lll:"YYYY [m.] MMMM D [d.], HH:mm [val.]",llll:"YYYY [m.] MMMM D [d.], ddd, HH:mm [val.]"},calendar:{sameDay:"[Šiandien] LT",nextDay:"[Rytoj] LT",nextWeek:"dddd LT",lastDay:"[Vakar] LT",lastWeek:"[Praėjusį] dddd LT",sameElse:"L"},relativeTime:{future:"po %s",past:"prieš %s",s:function(e,t,n,r){return t?"kelios sekundės":r?"kelių sekundžių":"kelias sekundes"},ss:o,m:n,mm:o,h:n,hh:o,d:n,dd:o,M:n,MM:o,y:n,yy:o},dayOfMonthOrdinalParse:/\d{1,2}-oji/,ordinal:function(e){return e+"-oji"},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={ss:"sekundes_sekundēm_sekunde_sekundes".split("_"),m:"minūtes_minūtēm_minūte_minūtes".split("_"),mm:"minūtes_minūtēm_minūte_minūtes".split("_"),h:"stundas_stundām_stunda_stundas".split("_"),hh:"stundas_stundām_stunda_stundas".split("_"),d:"dienas_dienām_diena_dienas".split("_"),dd:"dienas_dienām_diena_dienas".split("_"),M:"mēneša_mēnešiem_mēnesis_mēneši".split("_"),MM:"mēneša_mēnešiem_mēnesis_mēneši".split("_"),y:"gada_gadiem_gads_gadi".split("_"),yy:"gada_gadiem_gads_gadi".split("_")};function n(e,t,n){return n?t%10==1&&t%100!=11?e[2]:e[3]:t%10==1&&t%100!=11?e[0]:e[1]}function r(e,r,a){return e+" "+n(t[a],e,r)}function a(e,r,a){return n(t[a],e,r)}e.defineLocale("lv",{months:"janvāris_februāris_marts_aprīlis_maijs_jūnijs_jūlijs_augusts_septembris_oktobris_novembris_decembris".split("_"),monthsShort:"jan_feb_mar_apr_mai_jūn_jūl_aug_sep_okt_nov_dec".split("_"),weekdays:"svētdiena_pirmdiena_otrdiena_trešdiena_ceturtdiena_piektdiena_sestdiena".split("_"),weekdaysShort:"Sv_P_O_T_C_Pk_S".split("_"),weekdaysMin:"Sv_P_O_T_C_Pk_S".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY.",LL:"YYYY. [gada] D. MMMM",LLL:"YYYY. [gada] D. MMMM, HH:mm",LLLL:"YYYY. [gada] D. MMMM, dddd, HH:mm"},calendar:{sameDay:"[Šodien pulksten] LT",nextDay:"[Rīt pulksten] LT",nextWeek:"dddd [pulksten] LT",lastDay:"[Vakar pulksten] LT",lastWeek:"[Pagājušā] dddd [pulksten] LT",sameElse:"L"},relativeTime:{future:"pēc %s",past:"pirms %s",s:function(e,t){return t?"dažas sekundes":"dažām sekundēm"},ss:r,m:a,mm:r,h:a,hh:r,d:a,dd:r,M:a,MM:r,y:a,yy:r},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={words:{ss:["sekund","sekunda","sekundi"],m:["jedan minut","jednog minuta"],mm:["minut","minuta","minuta"],h:["jedan sat","jednog sata"],hh:["sat","sata","sati"],dd:["dan","dana","dana"],MM:["mjesec","mjeseca","mjeseci"],yy:["godina","godine","godina"]},correctGrammaticalCase:function(e,t){return 1===e?t[0]:e>=2&&e<=4?t[1]:t[2]},translate:function(e,n,r){var a=t.words[r];return 1===r.length?n?a[0]:a[1]:e+" "+t.correctGrammaticalCase(e,a)}};e.defineLocale("me",{months:"januar_februar_mart_april_maj_jun_jul_avgust_septembar_oktobar_novembar_decembar".split("_"),monthsShort:"jan._feb._mar._apr._maj_jun_jul_avg._sep._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sri._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd, D. MMMM YYYY H:mm"},calendar:{sameDay:"[danas u] LT",nextDay:"[sjutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedjelju] [u] LT";case 3:return"[u] [srijedu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[juče u] LT",lastWeek:function(){return["[prošle] [nedjelje] [u] LT","[prošlog] [ponedjeljka] [u] LT","[prošlog] [utorka] [u] LT","[prošle] [srijede] [u] LT","[prošlog] [četvrtka] [u] LT","[prošlog] [petka] [u] LT","[prošle] [subote] [u] LT"][this.day()]},sameElse:"L"},relativeTime:{future:"za %s",past:"prije %s",s:"nekoliko sekundi",ss:t.translate,m:t.translate,mm:t.translate,h:t.translate,hh:t.translate,d:"dan",dd:t.translate,M:"mjesec",MM:t.translate,y:"godinu",yy:t.translate},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("mi",{months:"Kohi-tāte_Hui-tanguru_Poutū-te-rangi_Paenga-whāwhā_Haratua_Pipiri_Hōngoingoi_Here-turi-kōkā_Mahuru_Whiringa-ā-nuku_Whiringa-ā-rangi_Hakihea".split("_"),monthsShort:"Kohi_Hui_Pou_Pae_Hara_Pipi_Hōngoi_Here_Mahu_Whi-nu_Whi-ra_Haki".split("_"),monthsRegex:/(?:['a-z\u0101\u014D\u016B]+\-?){1,3}/i,monthsStrictRegex:/(?:['a-z\u0101\u014D\u016B]+\-?){1,3}/i,monthsShortRegex:/(?:['a-z\u0101\u014D\u016B]+\-?){1,3}/i,monthsShortStrictRegex:/(?:['a-z\u0101\u014D\u016B]+\-?){1,2}/i,weekdays:"Rātapu_Mane_Tūrei_Wenerei_Tāite_Paraire_Hātarei".split("_"),weekdaysShort:"Ta_Ma_Tū_We_Tāi_Pa_Hā".split("_"),weekdaysMin:"Ta_Ma_Tū_We_Tāi_Pa_Hā".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [i] HH:mm",LLLL:"dddd, D MMMM YYYY [i] HH:mm"},calendar:{sameDay:"[i teie mahana, i] LT",nextDay:"[apopo i] LT",nextWeek:"dddd [i] LT",lastDay:"[inanahi i] LT",lastWeek:"dddd [whakamutunga i] LT",sameElse:"L"},relativeTime:{future:"i roto i %s",past:"%s i mua",s:"te hēkona ruarua",ss:"%d hēkona",m:"he meneti",mm:"%d meneti",h:"te haora",hh:"%d haora",d:"he ra",dd:"%d ra",M:"he marama",MM:"%d marama",y:"he tau",yy:"%d tau"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("mk",{months:"јануари_февруари_март_април_мај_јуни_јули_август_септември_октомври_ноември_декември".split("_"),monthsShort:"јан_фев_мар_апр_мај_јун_јул_авг_сеп_окт_ное_дек".split("_"),weekdays:"недела_понеделник_вторник_среда_четврток_петок_сабота".split("_"),weekdaysShort:"нед_пон_вто_сре_чет_пет_саб".split("_"),weekdaysMin:"нe_пo_вт_ср_че_пе_сa".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"D.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY H:mm",LLLL:"dddd, D MMMM YYYY H:mm"},calendar:{sameDay:"[Денес во] LT",nextDay:"[Утре во] LT",nextWeek:"[Во] dddd [во] LT",lastDay:"[Вчера во] LT",lastWeek:function(){switch(this.day()){case 0:case 3:case 6:return"[Изминатата] dddd [во] LT";case 1:case 2:case 4:case 5:return"[Изминатиот] dddd [во] LT"}},sameElse:"L"},relativeTime:{future:"после %s",past:"пред %s",s:"неколку секунди",ss:"%d секунди",m:"минута",mm:"%d минути",h:"час",hh:"%d часа",d:"ден",dd:"%d дена",M:"месец",MM:"%d месеци",y:"година",yy:"%d години"},dayOfMonthOrdinalParse:/\d{1,2}-(ев|ен|ти|ви|ри|ми)/,ordinal:function(e){var t=e%10,n=e%100;return 0===e?e+"-ев":0===n?e+"-ен":n>10&&n<20?e+"-ти":1===t?e+"-ви":2===t?e+"-ри":7===t||8===t?e+"-ми":e+"-ти"},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ml",{months:"ജനുവരി_ഫെബ്രുവരി_മാർച്ച്_ഏപ്രിൽ_മേയ്_ജൂൺ_ജൂലൈ_ഓഗസ്റ്റ്_സെപ്റ്റംബർ_ഒക്ടോബർ_നവംബർ_ഡിസംബർ".split("_"),monthsShort:"ജനു._ഫെബ്രു._മാർ._ഏപ്രി._മേയ്_ജൂൺ_ജൂലൈ._ഓഗ._സെപ്റ്റ._ഒക്ടോ._നവം._ഡിസം.".split("_"),monthsParseExact:!0,weekdays:"ഞായറാഴ്ച_തിങ്കളാഴ്ച_ചൊവ്വാഴ്ച_ബുധനാഴ്ച_വ്യാഴാഴ്ച_വെള്ളിയാഴ്ച_ശനിയാഴ്ച".split("_"),weekdaysShort:"ഞായർ_തിങ്കൾ_ചൊവ്വ_ബുധൻ_വ്യാഴം_വെള്ളി_ശനി".split("_"),weekdaysMin:"ഞാ_തി_ചൊ_ബു_വ്യാ_വെ_ശ".split("_"),longDateFormat:{LT:"A h:mm -നു",LTS:"A h:mm:ss -നു",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm -നു",LLLL:"dddd, D MMMM YYYY, A h:mm -നു"},calendar:{sameDay:"[ഇന്ന്] LT",nextDay:"[നാളെ] LT",nextWeek:"dddd, LT",lastDay:"[ഇന്നലെ] LT",lastWeek:"[കഴിഞ്ഞ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s കഴിഞ്ഞ്",past:"%s മുൻപ്",s:"അൽപ നിമിഷങ്ങൾ",ss:"%d സെക്കൻഡ്",m:"ഒരു മിനിറ്റ്",mm:"%d മിനിറ്റ്",h:"ഒരു മണിക്കൂർ",hh:"%d മണിക്കൂർ",d:"ഒരു ദിവസം",dd:"%d ദിവസം",M:"ഒരു മാസം",MM:"%d മാസം",y:"ഒരു വർഷം",yy:"%d വർഷം"},meridiemParse:/രാത്രി|രാവിലെ|ഉച്ച കഴിഞ്ഞ്|വൈകുന്നേരം|രാത്രി/i,meridiemHour:function(e,t){return 12===e&&(e=0),"രാത്രി"===t&&e>=4||"ഉച്ച കഴിഞ്ഞ്"===t||"വൈകുന്നേരം"===t?e+12:e},meridiem:function(e,t,n){return e<4?"രാത്രി":e<12?"രാവിലെ":e<17?"ഉച്ച കഴിഞ്ഞ്":e<20?"വൈകുന്നേരം":"രാത്രി"}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n,r){switch(n){case"s":return t?"хэдхэн секунд":"хэдхэн секундын";case"ss":return e+(t?" секунд":" секундын");case"m":case"mm":return e+(t?" минут":" минутын");case"h":case"hh":return e+(t?" цаг":" цагийн");case"d":case"dd":return e+(t?" өдөр":" өдрийн");case"M":case"MM":return e+(t?" сар":" сарын");case"y":case"yy":return e+(t?" жил":" жилийн");default:return e}}e.defineLocale("mn",{months:"Нэгдүгээр сар_Хоёрдугаар сар_Гуравдугаар сар_Дөрөвдүгээр сар_Тавдугаар сар_Зургадугаар сар_Долдугаар сар_Наймдугаар сар_Есдүгээр сар_Аравдугаар сар_Арван нэгдүгээр сар_Арван хоёрдугаар сар".split("_"),monthsShort:"1 сар_2 сар_3 сар_4 сар_5 сар_6 сар_7 сар_8 сар_9 сар_10 сар_11 сар_12 сар".split("_"),monthsParseExact:!0,weekdays:"Ням_Даваа_Мягмар_Лхагва_Пүрэв_Баасан_Бямба".split("_"),weekdaysShort:"Ням_Дав_Мяг_Лха_Пүр_Баа_Бям".split("_"),weekdaysMin:"Ня_Да_Мя_Лх_Пү_Ба_Бя".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"YYYY оны MMMMын D",LLL:"YYYY оны MMMMын D HH:mm",LLLL:"dddd, YYYY оны MMMMын D HH:mm"},meridiemParse:/ҮӨ|ҮХ/i,isPM:function(e){return"ҮХ"===e},meridiem:function(e,t,n){return e<12?"ҮӨ":"ҮХ"},calendar:{sameDay:"[Өнөөдөр] LT",nextDay:"[Маргааш] LT",nextWeek:"[Ирэх] dddd LT",lastDay:"[Өчигдөр] LT",lastWeek:"[Өнгөрсөн] dddd LT",sameElse:"L"},relativeTime:{future:"%s дараа",past:"%s өмнө",s:t,ss:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2} өдөр/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+" өдөр";default:return e}}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"१",2:"२",3:"३",4:"४",5:"५",6:"६",7:"७",8:"८",9:"९",0:"०"},n={"१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9","०":"0"};function r(e,t,n,r){var a="";if(t)switch(n){case"s":a="काही सेकंद";break;case"ss":a="%d सेकंद";break;case"m":a="एक मिनिट";break;case"mm":a="%d मिनिटे";break;case"h":a="एक तास";break;case"hh":a="%d तास";break;case"d":a="एक दिवस";break;case"dd":a="%d दिवस";break;case"M":a="एक महिना";break;case"MM":a="%d महिने";break;case"y":a="एक वर्ष";break;case"yy":a="%d वर्षे"}else switch(n){case"s":a="काही सेकंदां";break;case"ss":a="%d सेकंदां";break;case"m":a="एका मिनिटा";break;case"mm":a="%d मिनिटां";break;case"h":a="एका तासा";break;case"hh":a="%d तासां";break;case"d":a="एका दिवसा";break;case"dd":a="%d दिवसां";break;case"M":a="एका महिन्या";break;case"MM":a="%d महिन्यां";break;case"y":a="एका वर्षा";break;case"yy":a="%d वर्षां"}return a.replace(/%d/i,e)}e.defineLocale("mr",{months:"जानेवारी_फेब्रुवारी_मार्च_एप्रिल_मे_जून_जुलै_ऑगस्ट_सप्टेंबर_ऑक्टोबर_नोव्हेंबर_डिसेंबर".split("_"),monthsShort:"जाने._फेब्रु._मार्च._एप्रि._मे._जून._जुलै._ऑग._सप्टें._ऑक्टो._नोव्हें._डिसें.".split("_"),monthsParseExact:!0,weekdays:"रविवार_सोमवार_मंगळवार_बुधवार_गुरूवार_शुक्रवार_शनिवार".split("_"),weekdaysShort:"रवि_सोम_मंगळ_बुध_गुरू_शुक्र_शनि".split("_"),weekdaysMin:"र_सो_मं_बु_गु_शु_श".split("_"),longDateFormat:{LT:"A h:mm वाजता",LTS:"A h:mm:ss वाजता",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm वाजता",LLLL:"dddd, D MMMM YYYY, A h:mm वाजता"},calendar:{sameDay:"[आज] LT",nextDay:"[उद्या] LT",nextWeek:"dddd, LT",lastDay:"[काल] LT",lastWeek:"[मागील] dddd, LT",sameElse:"L"},relativeTime:{future:"%sमध्ये",past:"%sपूर्वी",s:r,ss:r,m:r,mm:r,h:r,hh:r,d:r,dd:r,M:r,MM:r,y:r,yy:r},preparse:function(e){return e.replace(/[१२३४५६७८९०]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/रात्री|सकाळी|दुपारी|सायंकाळी/,meridiemHour:function(e,t){return 12===e&&(e=0),"रात्री"===t?e<4?e:e+12:"सकाळी"===t?e:"दुपारी"===t?e>=10?e:e+12:"सायंकाळी"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"रात्री":e<10?"सकाळी":e<17?"दुपारी":e<20?"सायंकाळी":"रात्री"},week:{dow:0,doy:6}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ms",{months:"Januari_Februari_Mac_April_Mei_Jun_Julai_Ogos_September_Oktober_November_Disember".split("_"),monthsShort:"Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ogs_Sep_Okt_Nov_Dis".split("_"),weekdays:"Ahad_Isnin_Selasa_Rabu_Khamis_Jumaat_Sabtu".split("_"),weekdaysShort:"Ahd_Isn_Sel_Rab_Kha_Jum_Sab".split("_"),weekdaysMin:"Ah_Is_Sl_Rb_Km_Jm_Sb".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},meridiemParse:/pagi|tengahari|petang|malam/,meridiemHour:function(e,t){return 12===e&&(e=0),"pagi"===t?e:"tengahari"===t?e>=11?e:e+12:"petang"===t||"malam"===t?e+12:void 0},meridiem:function(e,t,n){return e<11?"pagi":e<15?"tengahari":e<19?"petang":"malam"},calendar:{sameDay:"[Hari ini pukul] LT",nextDay:"[Esok pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kelmarin pukul] LT",lastWeek:"dddd [lepas pukul] LT",sameElse:"L"},relativeTime:{future:"dalam %s",past:"%s yang lepas",s:"beberapa saat",ss:"%d saat",m:"seminit",mm:"%d minit",h:"sejam",hh:"%d jam",d:"sehari",dd:"%d hari",M:"sebulan",MM:"%d bulan",y:"setahun",yy:"%d tahun"},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ms-my",{months:"Januari_Februari_Mac_April_Mei_Jun_Julai_Ogos_September_Oktober_November_Disember".split("_"),monthsShort:"Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ogs_Sep_Okt_Nov_Dis".split("_"),weekdays:"Ahad_Isnin_Selasa_Rabu_Khamis_Jumaat_Sabtu".split("_"),weekdaysShort:"Ahd_Isn_Sel_Rab_Kha_Jum_Sab".split("_"),weekdaysMin:"Ah_Is_Sl_Rb_Km_Jm_Sb".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},meridiemParse:/pagi|tengahari|petang|malam/,meridiemHour:function(e,t){return 12===e&&(e=0),"pagi"===t?e:"tengahari"===t?e>=11?e:e+12:"petang"===t||"malam"===t?e+12:void 0},meridiem:function(e,t,n){return e<11?"pagi":e<15?"tengahari":e<19?"petang":"malam"},calendar:{sameDay:"[Hari ini pukul] LT",nextDay:"[Esok pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kelmarin pukul] LT",lastWeek:"dddd [lepas pukul] LT",sameElse:"L"},relativeTime:{future:"dalam %s",past:"%s yang lepas",s:"beberapa saat",ss:"%d saat",m:"seminit",mm:"%d minit",h:"sejam",hh:"%d jam",d:"sehari",dd:"%d hari",M:"sebulan",MM:"%d bulan",y:"setahun",yy:"%d tahun"},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("mt",{months:"Jannar_Frar_Marzu_April_Mejju_Ġunju_Lulju_Awwissu_Settembru_Ottubru_Novembru_Diċembru".split("_"),monthsShort:"Jan_Fra_Mar_Apr_Mej_Ġun_Lul_Aww_Set_Ott_Nov_Diċ".split("_"),weekdays:"Il-Ħadd_It-Tnejn_It-Tlieta_L-Erbgħa_Il-Ħamis_Il-Ġimgħa_Is-Sibt".split("_"),weekdaysShort:"Ħad_Tne_Tli_Erb_Ħam_Ġim_Sib".split("_"),weekdaysMin:"Ħa_Tn_Tl_Er_Ħa_Ġi_Si".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Illum fil-]LT",nextDay:"[Għada fil-]LT",nextWeek:"dddd [fil-]LT",lastDay:"[Il-bieraħ fil-]LT",lastWeek:"dddd [li għadda] [fil-]LT",sameElse:"L"},relativeTime:{future:"f’ %s",past:"%s ilu",s:"ftit sekondi",ss:"%d sekondi",m:"minuta",mm:"%d minuti",h:"siegħa",hh:"%d siegħat",d:"ġurnata",dd:"%d ġranet",M:"xahar",MM:"%d xhur",y:"sena",yy:"%d sni"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"၁",2:"၂",3:"၃",4:"၄",5:"၅",6:"၆",7:"၇",8:"၈",9:"၉",0:"၀"},n={"၁":"1","၂":"2","၃":"3","၄":"4","၅":"5","၆":"6","၇":"7","၈":"8","၉":"9","၀":"0"};e.defineLocale("my",{months:"ဇန်နဝါရီ_ဖေဖော်ဝါရီ_မတ်_ဧပြီ_မေ_ဇွန်_ဇူလိုင်_သြဂုတ်_စက်တင်ဘာ_အောက်တိုဘာ_နိုဝင်ဘာ_ဒီဇင်ဘာ".split("_"),monthsShort:"ဇန်_ဖေ_မတ်_ပြီ_မေ_ဇွန်_လိုင်_သြ_စက်_အောက်_နို_ဒီ".split("_"),weekdays:"တနင်္ဂနွေ_တနင်္လာ_အင်္ဂါ_ဗုဒ္ဓဟူး_ကြာသပတေး_သောကြာ_စနေ".split("_"),weekdaysShort:"နွေ_လာ_ဂါ_ဟူး_ကြာ_သော_နေ".split("_"),weekdaysMin:"နွေ_လာ_ဂါ_ဟူး_ကြာ_သော_နေ".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[ယနေ.] LT [မှာ]",nextDay:"[မနက်ဖြန်] LT [မှာ]",nextWeek:"dddd LT [မှာ]",lastDay:"[မနေ.က] LT [မှာ]",lastWeek:"[ပြီးခဲ့သော] dddd LT [မှာ]",sameElse:"L"},relativeTime:{future:"လာမည့် %s မှာ",past:"လွန်ခဲ့သော %s က",s:"စက္ကန်.အနည်းငယ်",ss:"%d စက္ကန့်",m:"တစ်မိနစ်",mm:"%d မိနစ်",h:"တစ်နာရီ",hh:"%d နာရီ",d:"တစ်ရက်",dd:"%d ရက်",M:"တစ်လ",MM:"%d လ",y:"တစ်နှစ်",yy:"%d နှစ်"},preparse:function(e){return e.replace(/[၁၂၃၄၅၆၇၈၉၀]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("nb",{months:"januar_februar_mars_april_mai_juni_juli_august_september_oktober_november_desember".split("_"),monthsShort:"jan._feb._mars_april_mai_juni_juli_aug._sep._okt._nov._des.".split("_"),monthsParseExact:!0,weekdays:"søndag_mandag_tirsdag_onsdag_torsdag_fredag_lørdag".split("_"),weekdaysShort:"sø._ma._ti._on._to._fr._lø.".split("_"),weekdaysMin:"sø_ma_ti_on_to_fr_lø".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY [kl.] HH:mm",LLLL:"dddd D. MMMM YYYY [kl.] HH:mm"},calendar:{sameDay:"[i dag kl.] LT",nextDay:"[i morgen kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[i går kl.] LT",lastWeek:"[forrige] dddd [kl.] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"%s siden",s:"noen sekunder",ss:"%d sekunder",m:"ett minutt",mm:"%d minutter",h:"en time",hh:"%d timer",d:"en dag",dd:"%d dager",M:"en måned",MM:"%d måneder",y:"ett år",yy:"%d år"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"१",2:"२",3:"३",4:"४",5:"५",6:"६",7:"७",8:"८",9:"९",0:"०"},n={"१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9","०":"0"};e.defineLocale("ne",{months:"जनवरी_फेब्रुवरी_मार्च_अप्रिल_मई_जुन_जुलाई_अगष्ट_सेप्टेम्बर_अक्टोबर_नोभेम्बर_डिसेम्बर".split("_"),monthsShort:"जन._फेब्रु._मार्च_अप्रि._मई_जुन_जुलाई._अग._सेप्ट._अक्टो._नोभे._डिसे.".split("_"),monthsParseExact:!0,weekdays:"आइतबार_सोमबार_मङ्गलबार_बुधबार_बिहिबार_शुक्रबार_शनिबार".split("_"),weekdaysShort:"आइत._सोम._मङ्गल._बुध._बिहि._शुक्र._शनि.".split("_"),weekdaysMin:"आ._सो._मं._बु._बि._शु._श.".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"Aको h:mm बजे",LTS:"Aको h:mm:ss बजे",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, Aको h:mm बजे",LLLL:"dddd, D MMMM YYYY, Aको h:mm बजे"},preparse:function(e){return e.replace(/[१२३४५६७८९०]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/राति|बिहान|दिउँसो|साँझ/,meridiemHour:function(e,t){return 12===e&&(e=0),"राति"===t?e<4?e:e+12:"बिहान"===t?e:"दिउँसो"===t?e>=10?e:e+12:"साँझ"===t?e+12:void 0},meridiem:function(e,t,n){return e<3?"राति":e<12?"बिहान":e<16?"दिउँसो":e<20?"साँझ":"राति"},calendar:{sameDay:"[आज] LT",nextDay:"[भोलि] LT",nextWeek:"[आउँदो] dddd[,] LT",lastDay:"[हिजो] LT",lastWeek:"[गएको] dddd[,] LT",sameElse:"L"},relativeTime:{future:"%sमा",past:"%s अगाडि",s:"केही क्षण",ss:"%d सेकेण्ड",m:"एक मिनेट",mm:"%d मिनेट",h:"एक घण्टा",hh:"%d घण्टा",d:"एक दिन",dd:"%d दिन",M:"एक महिना",MM:"%d महिना",y:"एक बर्ष",yy:"%d बर्ष"},week:{dow:0,doy:6}})}(n(8))},function(e,t,n){!function(e){"use strict";var t="jan._feb._mrt._apr._mei_jun._jul._aug._sep._okt._nov._dec.".split("_"),n="jan_feb_mrt_apr_mei_jun_jul_aug_sep_okt_nov_dec".split("_"),r=[/^jan/i,/^feb/i,/^maart|mrt.?$/i,/^apr/i,/^mei$/i,/^jun[i.]?$/i,/^jul[i.]?$/i,/^aug/i,/^sep/i,/^okt/i,/^nov/i,/^dec/i],a=/^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december|jan\.?|feb\.?|mrt\.?|apr\.?|ju[nl]\.?|aug\.?|sep\.?|okt\.?|nov\.?|dec\.?)/i;e.defineLocale("nl",{months:"januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december".split("_"),monthsShort:function(e,r){return e?/-MMM-/.test(r)?n[e.month()]:t[e.month()]:t},monthsRegex:a,monthsShortRegex:a,monthsStrictRegex:/^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december)/i,monthsShortStrictRegex:/^(jan\.?|feb\.?|mrt\.?|apr\.?|mei|ju[nl]\.?|aug\.?|sep\.?|okt\.?|nov\.?|dec\.?)/i,monthsParse:r,longMonthsParse:r,shortMonthsParse:r,weekdays:"zondag_maandag_dinsdag_woensdag_donderdag_vrijdag_zaterdag".split("_"),weekdaysShort:"zo._ma._di._wo._do._vr._za.".split("_"),weekdaysMin:"zo_ma_di_wo_do_vr_za".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD-MM-YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[vandaag om] LT",nextDay:"[morgen om] LT",nextWeek:"dddd [om] LT",lastDay:"[gisteren om] LT",lastWeek:"[afgelopen] dddd [om] LT",sameElse:"L"},relativeTime:{future:"over %s",past:"%s geleden",s:"een paar seconden",ss:"%d seconden",m:"één minuut",mm:"%d minuten",h:"één uur",hh:"%d uur",d:"één dag",dd:"%d dagen",M:"één maand",MM:"%d maanden",y:"één jaar",yy:"%d jaar"},dayOfMonthOrdinalParse:/\d{1,2}(ste|de)/,ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t="jan._feb._mrt._apr._mei_jun._jul._aug._sep._okt._nov._dec.".split("_"),n="jan_feb_mrt_apr_mei_jun_jul_aug_sep_okt_nov_dec".split("_"),r=[/^jan/i,/^feb/i,/^maart|mrt.?$/i,/^apr/i,/^mei$/i,/^jun[i.]?$/i,/^jul[i.]?$/i,/^aug/i,/^sep/i,/^okt/i,/^nov/i,/^dec/i],a=/^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december|jan\.?|feb\.?|mrt\.?|apr\.?|ju[nl]\.?|aug\.?|sep\.?|okt\.?|nov\.?|dec\.?)/i;e.defineLocale("nl-be",{months:"januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december".split("_"),monthsShort:function(e,r){return e?/-MMM-/.test(r)?n[e.month()]:t[e.month()]:t},monthsRegex:a,monthsShortRegex:a,monthsStrictRegex:/^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december)/i,monthsShortStrictRegex:/^(jan\.?|feb\.?|mrt\.?|apr\.?|mei|ju[nl]\.?|aug\.?|sep\.?|okt\.?|nov\.?|dec\.?)/i,monthsParse:r,longMonthsParse:r,shortMonthsParse:r,weekdays:"zondag_maandag_dinsdag_woensdag_donderdag_vrijdag_zaterdag".split("_"),weekdaysShort:"zo._ma._di._wo._do._vr._za.".split("_"),weekdaysMin:"zo_ma_di_wo_do_vr_za".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[vandaag om] LT",nextDay:"[morgen om] LT",nextWeek:"dddd [om] LT",lastDay:"[gisteren om] LT",lastWeek:"[afgelopen] dddd [om] LT",sameElse:"L"},relativeTime:{future:"over %s",past:"%s geleden",s:"een paar seconden",ss:"%d seconden",m:"één minuut",mm:"%d minuten",h:"één uur",hh:"%d uur",d:"één dag",dd:"%d dagen",M:"één maand",MM:"%d maanden",y:"één jaar",yy:"%d jaar"},dayOfMonthOrdinalParse:/\d{1,2}(ste|de)/,ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("nn",{months:"januar_februar_mars_april_mai_juni_juli_august_september_oktober_november_desember".split("_"),monthsShort:"jan_feb_mar_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_"),weekdays:"sundag_måndag_tysdag_onsdag_torsdag_fredag_laurdag".split("_"),weekdaysShort:"sun_mån_tys_ons_tor_fre_lau".split("_"),weekdaysMin:"su_må_ty_on_to_fr_lø".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY [kl.] H:mm",LLLL:"dddd D. MMMM YYYY [kl.] HH:mm"},calendar:{sameDay:"[I dag klokka] LT",nextDay:"[I morgon klokka] LT",nextWeek:"dddd [klokka] LT",lastDay:"[I går klokka] LT",lastWeek:"[Føregåande] dddd [klokka] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"%s sidan",s:"nokre sekund",ss:"%d sekund",m:"eit minutt",mm:"%d minutt",h:"ein time",hh:"%d timar",d:"ein dag",dd:"%d dagar",M:"ein månad",MM:"%d månader",y:"eit år",yy:"%d år"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"੧",2:"੨",3:"੩",4:"੪",5:"੫",6:"੬",7:"੭",8:"੮",9:"੯",0:"੦"},n={"੧":"1","੨":"2","੩":"3","੪":"4","੫":"5","੬":"6","੭":"7","੮":"8","੯":"9","੦":"0"};e.defineLocale("pa-in",{months:"ਜਨਵਰੀ_ਫ਼ਰਵਰੀ_ਮਾਰਚ_ਅਪ੍ਰੈਲ_ਮਈ_ਜੂਨ_ਜੁਲਾਈ_ਅਗਸਤ_ਸਤੰਬਰ_ਅਕਤੂਬਰ_ਨਵੰਬਰ_ਦਸੰਬਰ".split("_"),monthsShort:"ਜਨਵਰੀ_ਫ਼ਰਵਰੀ_ਮਾਰਚ_ਅਪ੍ਰੈਲ_ਮਈ_ਜੂਨ_ਜੁਲਾਈ_ਅਗਸਤ_ਸਤੰਬਰ_ਅਕਤੂਬਰ_ਨਵੰਬਰ_ਦਸੰਬਰ".split("_"),weekdays:"ਐਤਵਾਰ_ਸੋਮਵਾਰ_ਮੰਗਲਵਾਰ_ਬੁਧਵਾਰ_ਵੀਰਵਾਰ_ਸ਼ੁੱਕਰਵਾਰ_ਸ਼ਨੀਚਰਵਾਰ".split("_"),weekdaysShort:"ਐਤ_ਸੋਮ_ਮੰਗਲ_ਬੁਧ_ਵੀਰ_ਸ਼ੁਕਰ_ਸ਼ਨੀ".split("_"),weekdaysMin:"ਐਤ_ਸੋਮ_ਮੰਗਲ_ਬੁਧ_ਵੀਰ_ਸ਼ੁਕਰ_ਸ਼ਨੀ".split("_"),longDateFormat:{LT:"A h:mm ਵਜੇ",LTS:"A h:mm:ss ਵਜੇ",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm ਵਜੇ",LLLL:"dddd, D MMMM YYYY, A h:mm ਵਜੇ"},calendar:{sameDay:"[ਅਜ] LT",nextDay:"[ਕਲ] LT",nextWeek:"[ਅਗਲਾ] dddd, LT",lastDay:"[ਕਲ] LT",lastWeek:"[ਪਿਛਲੇ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s ਵਿੱਚ",past:"%s ਪਿਛਲੇ",s:"ਕੁਝ ਸਕਿੰਟ",ss:"%d ਸਕਿੰਟ",m:"ਇਕ ਮਿੰਟ",mm:"%d ਮਿੰਟ",h:"ਇੱਕ ਘੰਟਾ",hh:"%d ਘੰਟੇ",d:"ਇੱਕ ਦਿਨ",dd:"%d ਦਿਨ",M:"ਇੱਕ ਮਹੀਨਾ",MM:"%d ਮਹੀਨੇ",y:"ਇੱਕ ਸਾਲ",yy:"%d ਸਾਲ"},preparse:function(e){return e.replace(/[੧੨੩੪੫੬੭੮੯੦]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/ਰਾਤ|ਸਵੇਰ|ਦੁਪਹਿਰ|ਸ਼ਾਮ/,meridiemHour:function(e,t){return 12===e&&(e=0),"ਰਾਤ"===t?e<4?e:e+12:"ਸਵੇਰ"===t?e:"ਦੁਪਹਿਰ"===t?e>=10?e:e+12:"ਸ਼ਾਮ"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"ਰਾਤ":e<10?"ਸਵੇਰ":e<17?"ਦੁਪਹਿਰ":e<20?"ਸ਼ਾਮ":"ਰਾਤ"},week:{dow:0,doy:6}})}(n(8))},function(e,t,n){!function(e){"use strict";var t="styczeń_luty_marzec_kwiecień_maj_czerwiec_lipiec_sierpień_wrzesień_październik_listopad_grudzień".split("_"),n="stycznia_lutego_marca_kwietnia_maja_czerwca_lipca_sierpnia_września_października_listopada_grudnia".split("_");function r(e){return e%10<5&&e%10>1&&~~(e/10)%10!=1}function a(e,t,n){var a=e+" ";switch(n){case"ss":return a+(r(e)?"sekundy":"sekund");case"m":return t?"minuta":"minutę";case"mm":return a+(r(e)?"minuty":"minut");case"h":return t?"godzina":"godzinę";case"hh":return a+(r(e)?"godziny":"godzin");case"MM":return a+(r(e)?"miesiące":"miesięcy");case"yy":return a+(r(e)?"lata":"lat")}}e.defineLocale("pl",{months:function(e,r){return e?""===r?"("+n[e.month()]+"|"+t[e.month()]+")":/D MMMM/.test(r)?n[e.month()]:t[e.month()]:t},monthsShort:"sty_lut_mar_kwi_maj_cze_lip_sie_wrz_paź_lis_gru".split("_"),weekdays:"niedziela_poniedziałek_wtorek_środa_czwartek_piątek_sobota".split("_"),weekdaysShort:"ndz_pon_wt_śr_czw_pt_sob".split("_"),weekdaysMin:"Nd_Pn_Wt_Śr_Cz_Pt_So".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Dziś o] LT",nextDay:"[Jutro o] LT",nextWeek:function(){switch(this.day()){case 0:return"[W niedzielę o] LT";case 2:return"[We wtorek o] LT";case 3:return"[W środę o] LT";case 6:return"[W sobotę o] LT";default:return"[W] dddd [o] LT"}},lastDay:"[Wczoraj o] LT",lastWeek:function(){switch(this.day()){case 0:return"[W zeszłą niedzielę o] LT";case 3:return"[W zeszłą środę o] LT";case 6:return"[W zeszłą sobotę o] LT";default:return"[W zeszły] dddd [o] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"%s temu",s:"kilka sekund",ss:a,m:a,mm:a,h:a,hh:a,d:"1 dzień",dd:"%d dni",M:"miesiąc",MM:a,y:"rok",yy:a},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("pt",{months:"Janeiro_Fevereiro_Março_Abril_Maio_Junho_Julho_Agosto_Setembro_Outubro_Novembro_Dezembro".split("_"),monthsShort:"Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez".split("_"),weekdays:"Domingo_Segunda-feira_Terça-feira_Quarta-feira_Quinta-feira_Sexta-feira_Sábado".split("_"),weekdaysShort:"Dom_Seg_Ter_Qua_Qui_Sex_Sáb".split("_"),weekdaysMin:"Do_2ª_3ª_4ª_5ª_6ª_Sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY HH:mm",LLLL:"dddd, D [de] MMMM [de] YYYY HH:mm"},calendar:{sameDay:"[Hoje às] LT",nextDay:"[Amanhã às] LT",nextWeek:"dddd [às] LT",lastDay:"[Ontem às] LT",lastWeek:function(){return 0===this.day()||6===this.day()?"[Último] dddd [às] LT":"[Última] dddd [às] LT"},sameElse:"L"},relativeTime:{future:"em %s",past:"há %s",s:"segundos",ss:"%d segundos",m:"um minuto",mm:"%d minutos",h:"uma hora",hh:"%d horas",d:"um dia",dd:"%d dias",M:"um mês",MM:"%d meses",y:"um ano",yy:"%d anos"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("pt-br",{months:"Janeiro_Fevereiro_Março_Abril_Maio_Junho_Julho_Agosto_Setembro_Outubro_Novembro_Dezembro".split("_"),monthsShort:"Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez".split("_"),weekdays:"Domingo_Segunda-feira_Terça-feira_Quarta-feira_Quinta-feira_Sexta-feira_Sábado".split("_"),weekdaysShort:"Dom_Seg_Ter_Qua_Qui_Sex_Sáb".split("_"),weekdaysMin:"Do_2ª_3ª_4ª_5ª_6ª_Sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY [às] HH:mm",LLLL:"dddd, D [de] MMMM [de] YYYY [às] HH:mm"},calendar:{sameDay:"[Hoje às] LT",nextDay:"[Amanhã às] LT",nextWeek:"dddd [às] LT",lastDay:"[Ontem às] LT",lastWeek:function(){return 0===this.day()||6===this.day()?"[Último] dddd [às] LT":"[Última] dddd [às] LT"},sameElse:"L"},relativeTime:{future:"em %s",past:"há %s",s:"poucos segundos",ss:"%d segundos",m:"um minuto",mm:"%d minutos",h:"uma hora",hh:"%d horas",d:"um dia",dd:"%d dias",M:"um mês",MM:"%d meses",y:"um ano",yy:"%d anos"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº"})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n){var r=" ";return(e%100>=20||e>=100&&e%100==0)&&(r=" de "),e+r+{ss:"secunde",mm:"minute",hh:"ore",dd:"zile",MM:"luni",yy:"ani"}[n]}e.defineLocale("ro",{months:"ianuarie_februarie_martie_aprilie_mai_iunie_iulie_august_septembrie_octombrie_noiembrie_decembrie".split("_"),monthsShort:"ian._febr._mart._apr._mai_iun._iul._aug._sept._oct._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"duminică_luni_marți_miercuri_joi_vineri_sâmbătă".split("_"),weekdaysShort:"Dum_Lun_Mar_Mie_Joi_Vin_Sâm".split("_"),weekdaysMin:"Du_Lu_Ma_Mi_Jo_Vi_Sâ".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY H:mm",LLLL:"dddd, D MMMM YYYY H:mm"},calendar:{sameDay:"[azi la] LT",nextDay:"[mâine la] LT",nextWeek:"dddd [la] LT",lastDay:"[ieri la] LT",lastWeek:"[fosta] dddd [la] LT",sameElse:"L"},relativeTime:{future:"peste %s",past:"%s în urmă",s:"câteva secunde",ss:t,m:"un minut",mm:t,h:"o oră",hh:t,d:"o zi",dd:t,M:"o lună",MM:t,y:"un an",yy:t},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n){var r,a,o={ss:t?"секунда_секунды_секунд":"секунду_секунды_секунд",mm:t?"минута_минуты_минут":"минуту_минуты_минут",hh:"час_часа_часов",dd:"день_дня_дней",MM:"месяц_месяца_месяцев",yy:"год_года_лет"};return"m"===n?t?"минута":"минуту":e+" "+(r=+e,a=o[n].split("_"),r%10==1&&r%100!=11?a[0]:r%10>=2&&r%10<=4&&(r%100<10||r%100>=20)?a[1]:a[2])}var n=[/^янв/i,/^фев/i,/^мар/i,/^апр/i,/^ма[йя]/i,/^июн/i,/^июл/i,/^авг/i,/^сен/i,/^окт/i,/^ноя/i,/^дек/i];e.defineLocale("ru",{months:{format:"января_февраля_марта_апреля_мая_июня_июля_августа_сентября_октября_ноября_декабря".split("_"),standalone:"январь_февраль_март_апрель_май_июнь_июль_август_сентябрь_октябрь_ноябрь_декабрь".split("_")},monthsShort:{format:"янв._февр._мар._апр._мая_июня_июля_авг._сент._окт._нояб._дек.".split("_"),standalone:"янв._февр._март_апр._май_июнь_июль_авг._сент._окт._нояб._дек.".split("_")},weekdays:{standalone:"воскресенье_понедельник_вторник_среда_четверг_пятница_суббота".split("_"),format:"воскресенье_понедельник_вторник_среду_четверг_пятницу_субботу".split("_"),isFormat:/\[ ?[Вв] ?(?:прошлую|следующую|эту)? ?\] ?dddd/},weekdaysShort:"вс_пн_вт_ср_чт_пт_сб".split("_"),weekdaysMin:"вс_пн_вт_ср_чт_пт_сб".split("_"),monthsParse:n,longMonthsParse:n,shortMonthsParse:n,monthsRegex:/^(январ[ья]|янв\.?|феврал[ья]|февр?\.?|марта?|мар\.?|апрел[ья]|апр\.?|ма[йя]|июн[ья]|июн\.?|июл[ья]|июл\.?|августа?|авг\.?|сентябр[ья]|сент?\.?|октябр[ья]|окт\.?|ноябр[ья]|нояб?\.?|декабр[ья]|дек\.?)/i,monthsShortRegex:/^(январ[ья]|янв\.?|феврал[ья]|февр?\.?|марта?|мар\.?|апрел[ья]|апр\.?|ма[йя]|июн[ья]|июн\.?|июл[ья]|июл\.?|августа?|авг\.?|сентябр[ья]|сент?\.?|октябр[ья]|окт\.?|ноябр[ья]|нояб?\.?|декабр[ья]|дек\.?)/i,monthsStrictRegex:/^(январ[яь]|феврал[яь]|марта?|апрел[яь]|ма[яй]|июн[яь]|июл[яь]|августа?|сентябр[яь]|октябр[яь]|ноябр[яь]|декабр[яь])/i,monthsShortStrictRegex:/^(янв\.|февр?\.|мар[т.]|апр\.|ма[яй]|июн[ья.]|июл[ья.]|авг\.|сент?\.|окт\.|нояб?\.|дек\.)/i,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY г.",LLL:"D MMMM YYYY г., H:mm",LLLL:"dddd, D MMMM YYYY г., H:mm"},calendar:{sameDay:"[Сегодня, в] LT",nextDay:"[Завтра, в] LT",lastDay:"[Вчера, в] LT",nextWeek:function(e){if(e.week()===this.week())return 2===this.day()?"[Во] dddd, [в] LT":"[В] dddd, [в] LT";switch(this.day()){case 0:return"[В следующее] dddd, [в] LT";case 1:case 2:case 4:return"[В следующий] dddd, [в] LT";case 3:case 5:case 6:return"[В следующую] dddd, [в] LT"}},lastWeek:function(e){if(e.week()===this.week())return 2===this.day()?"[Во] dddd, [в] LT":"[В] dddd, [в] LT";switch(this.day()){case 0:return"[В прошлое] dddd, [в] LT";case 1:case 2:case 4:return"[В прошлый] dddd, [в] LT";case 3:case 5:case 6:return"[В прошлую] dddd, [в] LT"}},sameElse:"L"},relativeTime:{future:"через %s",past:"%s назад",s:"несколько секунд",ss:t,m:t,mm:t,h:"час",hh:t,d:"день",dd:t,M:"месяц",MM:t,y:"год",yy:t},meridiemParse:/ночи|утра|дня|вечера/i,isPM:function(e){return/^(дня|вечера)$/.test(e)},meridiem:function(e,t,n){return e<4?"ночи":e<12?"утра":e<17?"дня":"вечера"},dayOfMonthOrdinalParse:/\d{1,2}-(й|го|я)/,ordinal:function(e,t){switch(t){case"M":case"d":case"DDD":return e+"-й";case"D":return e+"-го";case"w":case"W":return e+"-я";default:return e}},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t=["جنوري","فيبروري","مارچ","اپريل","مئي","جون","جولاءِ","آگسٽ","سيپٽمبر","آڪٽوبر","نومبر","ڊسمبر"],n=["آچر","سومر","اڱارو","اربع","خميس","جمع","ڇنڇر"];e.defineLocale("sd",{months:t,monthsShort:t,weekdays:n,weekdaysShort:n,weekdaysMin:n,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd، D MMMM YYYY HH:mm"},meridiemParse:/صبح|شام/,isPM:function(e){return"شام"===e},meridiem:function(e,t,n){return e<12?"صبح":"شام"},calendar:{sameDay:"[اڄ] LT",nextDay:"[سڀاڻي] LT",nextWeek:"dddd [اڳين هفتي تي] LT",lastDay:"[ڪالهه] LT",lastWeek:"[گزريل هفتي] dddd [تي] LT",sameElse:"L"},relativeTime:{future:"%s پوء",past:"%s اڳ",s:"چند سيڪنڊ",ss:"%d سيڪنڊ",m:"هڪ منٽ",mm:"%d منٽ",h:"هڪ ڪلاڪ",hh:"%d ڪلاڪ",d:"هڪ ڏينهن",dd:"%d ڏينهن",M:"هڪ مهينو",MM:"%d مهينا",y:"هڪ سال",yy:"%d سال"},preparse:function(e){return e.replace(/،/g,",")},postformat:function(e){return e.replace(/,/g,"،")},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("se",{months:"ođđajagemánnu_guovvamánnu_njukčamánnu_cuoŋománnu_miessemánnu_geassemánnu_suoidnemánnu_borgemánnu_čakčamánnu_golggotmánnu_skábmamánnu_juovlamánnu".split("_"),monthsShort:"ođđj_guov_njuk_cuo_mies_geas_suoi_borg_čakč_golg_skáb_juov".split("_"),weekdays:"sotnabeaivi_vuossárga_maŋŋebárga_gaskavahkku_duorastat_bearjadat_lávvardat".split("_"),weekdaysShort:"sotn_vuos_maŋ_gask_duor_bear_láv".split("_"),weekdaysMin:"s_v_m_g_d_b_L".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"MMMM D. [b.] YYYY",LLL:"MMMM D. [b.] YYYY [ti.] HH:mm",LLLL:"dddd, MMMM D. [b.] YYYY [ti.] HH:mm"},calendar:{sameDay:"[otne ti] LT",nextDay:"[ihttin ti] LT",nextWeek:"dddd [ti] LT",lastDay:"[ikte ti] LT",lastWeek:"[ovddit] dddd [ti] LT",sameElse:"L"},relativeTime:{future:"%s geažes",past:"maŋit %s",s:"moadde sekunddat",ss:"%d sekunddat",m:"okta minuhta",mm:"%d minuhtat",h:"okta diimmu",hh:"%d diimmut",d:"okta beaivi",dd:"%d beaivvit",M:"okta mánnu",MM:"%d mánut",y:"okta jahki",yy:"%d jagit"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("si",{months:"ජනවාරි_පෙබරවාරි_මාර්තු_අප්‍රේල්_මැයි_ජූනි_ජූලි_අගෝස්තු_සැප්තැම්බර්_ඔක්තෝබර්_නොවැම්බර්_දෙසැම්බර්".split("_"),monthsShort:"ජන_පෙබ_මාර්_අප්_මැයි_ජූනි_ජූලි_අගෝ_සැප්_ඔක්_නොවැ_දෙසැ".split("_"),weekdays:"ඉරිදා_සඳුදා_අඟහරුවාදා_බදාදා_බ්‍රහස්පතින්දා_සිකුරාදා_සෙනසුරාදා".split("_"),weekdaysShort:"ඉරි_සඳු_අඟ_බදා_බ්‍රහ_සිකු_සෙන".split("_"),weekdaysMin:"ඉ_ස_අ_බ_බ්‍ර_සි_සෙ".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"a h:mm",LTS:"a h:mm:ss",L:"YYYY/MM/DD",LL:"YYYY MMMM D",LLL:"YYYY MMMM D, a h:mm",LLLL:"YYYY MMMM D [වැනි] dddd, a h:mm:ss"},calendar:{sameDay:"[අද] LT[ට]",nextDay:"[හෙට] LT[ට]",nextWeek:"dddd LT[ට]",lastDay:"[ඊයේ] LT[ට]",lastWeek:"[පසුගිය] dddd LT[ට]",sameElse:"L"},relativeTime:{future:"%sකින්",past:"%sකට පෙර",s:"තත්පර කිහිපය",ss:"තත්පර %d",m:"මිනිත්තුව",mm:"මිනිත්තු %d",h:"පැය",hh:"පැය %d",d:"දිනය",dd:"දින %d",M:"මාසය",MM:"මාස %d",y:"වසර",yy:"වසර %d"},dayOfMonthOrdinalParse:/\d{1,2} වැනි/,ordinal:function(e){return e+" වැනි"},meridiemParse:/පෙර වරු|පස් වරු|පෙ.ව|ප.ව./,isPM:function(e){return"ප.ව."===e||"පස් වරු"===e},meridiem:function(e,t,n){return e>11?n?"ප.ව.":"පස් වරු":n?"පෙ.ව.":"පෙර වරු"}})}(n(8))},function(e,t,n){!function(e){"use strict";var t="január_február_marec_apríl_máj_jún_júl_august_september_október_november_december".split("_"),n="jan_feb_mar_apr_máj_jún_júl_aug_sep_okt_nov_dec".split("_");function r(e){return e>1&&e<5}function a(e,t,n,a){var o=e+" ";switch(n){case"s":return t||a?"pár sekúnd":"pár sekundami";case"ss":return t||a?o+(r(e)?"sekundy":"sekúnd"):o+"sekundami";case"m":return t?"minúta":a?"minútu":"minútou";case"mm":return t||a?o+(r(e)?"minúty":"minút"):o+"minútami";case"h":return t?"hodina":a?"hodinu":"hodinou";case"hh":return t||a?o+(r(e)?"hodiny":"hodín"):o+"hodinami";case"d":return t||a?"deň":"dňom";case"dd":return t||a?o+(r(e)?"dni":"dní"):o+"dňami";case"M":return t||a?"mesiac":"mesiacom";case"MM":return t||a?o+(r(e)?"mesiace":"mesiacov"):o+"mesiacmi";case"y":return t||a?"rok":"rokom";case"yy":return t||a?o+(r(e)?"roky":"rokov"):o+"rokmi"}}e.defineLocale("sk",{months:t,monthsShort:n,weekdays:"nedeľa_pondelok_utorok_streda_štvrtok_piatok_sobota".split("_"),weekdaysShort:"ne_po_ut_st_št_pi_so".split("_"),weekdaysMin:"ne_po_ut_st_št_pi_so".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd D. MMMM YYYY H:mm"},calendar:{sameDay:"[dnes o] LT",nextDay:"[zajtra o] LT",nextWeek:function(){switch(this.day()){case 0:return"[v nedeľu o] LT";case 1:case 2:return"[v] dddd [o] LT";case 3:return"[v stredu o] LT";case 4:return"[vo štvrtok o] LT";case 5:return"[v piatok o] LT";case 6:return"[v sobotu o] LT"}},lastDay:"[včera o] LT",lastWeek:function(){switch(this.day()){case 0:return"[minulú nedeľu o] LT";case 1:case 2:return"[minulý] dddd [o] LT";case 3:return"[minulú stredu o] LT";case 4:case 5:return"[minulý] dddd [o] LT";case 6:return"[minulú sobotu o] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"pred %s",s:a,ss:a,m:a,mm:a,h:a,hh:a,d:a,dd:a,M:a,MM:a,y:a,yy:a},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n,r){var a=e+" ";switch(n){case"s":return t||r?"nekaj sekund":"nekaj sekundami";case"ss":return a+=1===e?t?"sekundo":"sekundi":2===e?t||r?"sekundi":"sekundah":e<5?t||r?"sekunde":"sekundah":"sekund";case"m":return t?"ena minuta":"eno minuto";case"mm":return a+=1===e?t?"minuta":"minuto":2===e?t||r?"minuti":"minutama":e<5?t||r?"minute":"minutami":t||r?"minut":"minutami";case"h":return t?"ena ura":"eno uro";case"hh":return a+=1===e?t?"ura":"uro":2===e?t||r?"uri":"urama":e<5?t||r?"ure":"urami":t||r?"ur":"urami";case"d":return t||r?"en dan":"enim dnem";case"dd":return a+=1===e?t||r?"dan":"dnem":2===e?t||r?"dni":"dnevoma":t||r?"dni":"dnevi";case"M":return t||r?"en mesec":"enim mesecem";case"MM":return a+=1===e?t||r?"mesec":"mesecem":2===e?t||r?"meseca":"mesecema":e<5?t||r?"mesece":"meseci":t||r?"mesecev":"meseci";case"y":return t||r?"eno leto":"enim letom";case"yy":return a+=1===e?t||r?"leto":"letom":2===e?t||r?"leti":"letoma":e<5?t||r?"leta":"leti":t||r?"let":"leti"}}e.defineLocale("sl",{months:"januar_februar_marec_april_maj_junij_julij_avgust_september_oktober_november_december".split("_"),monthsShort:"jan._feb._mar._apr._maj._jun._jul._avg._sep._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"nedelja_ponedeljek_torek_sreda_četrtek_petek_sobota".split("_"),weekdaysShort:"ned._pon._tor._sre._čet._pet._sob.".split("_"),weekdaysMin:"ne_po_to_sr_če_pe_so".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd, D. MMMM YYYY H:mm"},calendar:{sameDay:"[danes ob] LT",nextDay:"[jutri ob] LT",nextWeek:function(){switch(this.day()){case 0:return"[v] [nedeljo] [ob] LT";case 3:return"[v] [sredo] [ob] LT";case 6:return"[v] [soboto] [ob] LT";case 1:case 2:case 4:case 5:return"[v] dddd [ob] LT"}},lastDay:"[včeraj ob] LT",lastWeek:function(){switch(this.day()){case 0:return"[prejšnjo] [nedeljo] [ob] LT";case 3:return"[prejšnjo] [sredo] [ob] LT";case 6:return"[prejšnjo] [soboto] [ob] LT";case 1:case 2:case 4:case 5:return"[prejšnji] dddd [ob] LT"}},sameElse:"L"},relativeTime:{future:"čez %s",past:"pred %s",s:t,ss:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("sq",{months:"Janar_Shkurt_Mars_Prill_Maj_Qershor_Korrik_Gusht_Shtator_Tetor_Nëntor_Dhjetor".split("_"),monthsShort:"Jan_Shk_Mar_Pri_Maj_Qer_Kor_Gus_Sht_Tet_Nën_Dhj".split("_"),weekdays:"E Diel_E Hënë_E Martë_E Mërkurë_E Enjte_E Premte_E Shtunë".split("_"),weekdaysShort:"Die_Hën_Mar_Mër_Enj_Pre_Sht".split("_"),weekdaysMin:"D_H_Ma_Më_E_P_Sh".split("_"),weekdaysParseExact:!0,meridiemParse:/PD|MD/,isPM:function(e){return"M"===e.charAt(0)},meridiem:function(e,t,n){return e<12?"PD":"MD"},longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Sot në] LT",nextDay:"[Nesër në] LT",nextWeek:"dddd [në] LT",lastDay:"[Dje në] LT",lastWeek:"dddd [e kaluar në] LT",sameElse:"L"},relativeTime:{future:"në %s",past:"%s më parë",s:"disa sekonda",ss:"%d sekonda",m:"një minutë",mm:"%d minuta",h:"një orë",hh:"%d orë",d:"një ditë",dd:"%d ditë",M:"një muaj",MM:"%d muaj",y:"një vit",yy:"%d vite"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={words:{ss:["sekunda","sekunde","sekundi"],m:["jedan minut","jedne minute"],mm:["minut","minute","minuta"],h:["jedan sat","jednog sata"],hh:["sat","sata","sati"],dd:["dan","dana","dana"],MM:["mesec","meseca","meseci"],yy:["godina","godine","godina"]},correctGrammaticalCase:function(e,t){return 1===e?t[0]:e>=2&&e<=4?t[1]:t[2]},translate:function(e,n,r){var a=t.words[r];return 1===r.length?n?a[0]:a[1]:e+" "+t.correctGrammaticalCase(e,a)}};e.defineLocale("sr",{months:"januar_februar_mart_april_maj_jun_jul_avgust_septembar_oktobar_novembar_decembar".split("_"),monthsShort:"jan._feb._mar._apr._maj_jun_jul_avg._sep._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"nedelja_ponedeljak_utorak_sreda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sre._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd, D. MMMM YYYY H:mm"},calendar:{sameDay:"[danas u] LT",nextDay:"[sutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedelju] [u] LT";case 3:return"[u] [sredu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[juče u] LT",lastWeek:function(){return["[prošle] [nedelje] [u] LT","[prošlog] [ponedeljka] [u] LT","[prošlog] [utorka] [u] LT","[prošle] [srede] [u] LT","[prošlog] [četvrtka] [u] LT","[prošlog] [petka] [u] LT","[prošle] [subote] [u] LT"][this.day()]},sameElse:"L"},relativeTime:{future:"za %s",past:"pre %s",s:"nekoliko sekundi",ss:t.translate,m:t.translate,mm:t.translate,h:t.translate,hh:t.translate,d:"dan",dd:t.translate,M:"mesec",MM:t.translate,y:"godinu",yy:t.translate},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={words:{ss:["секунда","секунде","секунди"],m:["један минут","једне минуте"],mm:["минут","минуте","минута"],h:["један сат","једног сата"],hh:["сат","сата","сати"],dd:["дан","дана","дана"],MM:["месец","месеца","месеци"],yy:["година","године","година"]},correctGrammaticalCase:function(e,t){return 1===e?t[0]:e>=2&&e<=4?t[1]:t[2]},translate:function(e,n,r){var a=t.words[r];return 1===r.length?n?a[0]:a[1]:e+" "+t.correctGrammaticalCase(e,a)}};e.defineLocale("sr-cyrl",{months:"јануар_фебруар_март_април_мај_јун_јул_август_септембар_октобар_новембар_децембар".split("_"),monthsShort:"јан._феб._мар._апр._мај_јун_јул_авг._сеп._окт._нов._дец.".split("_"),monthsParseExact:!0,weekdays:"недеља_понедељак_уторак_среда_четвртак_петак_субота".split("_"),weekdaysShort:"нед._пон._уто._сре._чет._пет._суб.".split("_"),weekdaysMin:"не_по_ут_ср_че_пе_су".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd, D. MMMM YYYY H:mm"},calendar:{sameDay:"[данас у] LT",nextDay:"[сутра у] LT",nextWeek:function(){switch(this.day()){case 0:return"[у] [недељу] [у] LT";case 3:return"[у] [среду] [у] LT";case 6:return"[у] [суботу] [у] LT";case 1:case 2:case 4:case 5:return"[у] dddd [у] LT"}},lastDay:"[јуче у] LT",lastWeek:function(){return["[прошле] [недеље] [у] LT","[прошлог] [понедељка] [у] LT","[прошлог] [уторка] [у] LT","[прошле] [среде] [у] LT","[прошлог] [четвртка] [у] LT","[прошлог] [петка] [у] LT","[прошле] [суботе] [у] LT"][this.day()]},sameElse:"L"},relativeTime:{future:"за %s",past:"пре %s",s:"неколико секунди",ss:t.translate,m:t.translate,mm:t.translate,h:t.translate,hh:t.translate,d:"дан",dd:t.translate,M:"месец",MM:t.translate,y:"годину",yy:t.translate},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ss",{months:"Bhimbidvwane_Indlovana_Indlov'lenkhulu_Mabasa_Inkhwekhweti_Inhlaba_Kholwane_Ingci_Inyoni_Imphala_Lweti_Ingongoni".split("_"),monthsShort:"Bhi_Ina_Inu_Mab_Ink_Inh_Kho_Igc_Iny_Imp_Lwe_Igo".split("_"),weekdays:"Lisontfo_Umsombuluko_Lesibili_Lesitsatfu_Lesine_Lesihlanu_Umgcibelo".split("_"),weekdaysShort:"Lis_Umb_Lsb_Les_Lsi_Lsh_Umg".split("_"),weekdaysMin:"Li_Us_Lb_Lt_Ls_Lh_Ug".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[Namuhla nga] LT",nextDay:"[Kusasa nga] LT",nextWeek:"dddd [nga] LT",lastDay:"[Itolo nga] LT",lastWeek:"dddd [leliphelile] [nga] LT",sameElse:"L"},relativeTime:{future:"nga %s",past:"wenteka nga %s",s:"emizuzwana lomcane",ss:"%d mzuzwana",m:"umzuzu",mm:"%d emizuzu",h:"lihora",hh:"%d emahora",d:"lilanga",dd:"%d emalanga",M:"inyanga",MM:"%d tinyanga",y:"umnyaka",yy:"%d iminyaka"},meridiemParse:/ekuseni|emini|entsambama|ebusuku/,meridiem:function(e,t,n){return e<11?"ekuseni":e<15?"emini":e<19?"entsambama":"ebusuku"},meridiemHour:function(e,t){return 12===e&&(e=0),"ekuseni"===t?e:"emini"===t?e>=11?e:e+12:"entsambama"===t||"ebusuku"===t?0===e?0:e+12:void 0},dayOfMonthOrdinalParse:/\d{1,2}/,ordinal:"%d",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("sv",{months:"januari_februari_mars_april_maj_juni_juli_augusti_september_oktober_november_december".split("_"),monthsShort:"jan_feb_mar_apr_maj_jun_jul_aug_sep_okt_nov_dec".split("_"),weekdays:"söndag_måndag_tisdag_onsdag_torsdag_fredag_lördag".split("_"),weekdaysShort:"sön_mån_tis_ons_tor_fre_lör".split("_"),weekdaysMin:"sö_må_ti_on_to_fr_lö".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [kl.] HH:mm",LLLL:"dddd D MMMM YYYY [kl.] HH:mm",lll:"D MMM YYYY HH:mm",llll:"ddd D MMM YYYY HH:mm"},calendar:{sameDay:"[Idag] LT",nextDay:"[Imorgon] LT",lastDay:"[Igår] LT",nextWeek:"[På] dddd LT",lastWeek:"[I] dddd[s] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"för %s sedan",s:"några sekunder",ss:"%d sekunder",m:"en minut",mm:"%d minuter",h:"en timme",hh:"%d timmar",d:"en dag",dd:"%d dagar",M:"en månad",MM:"%d månader",y:"ett år",yy:"%d år"},dayOfMonthOrdinalParse:/\d{1,2}(e|a)/,ordinal:function(e){var t=e%10,n=1==~~(e%100/10)?"e":1===t?"a":2===t?"a":"e";return e+n},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("sw",{months:"Januari_Februari_Machi_Aprili_Mei_Juni_Julai_Agosti_Septemba_Oktoba_Novemba_Desemba".split("_"),monthsShort:"Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ago_Sep_Okt_Nov_Des".split("_"),weekdays:"Jumapili_Jumatatu_Jumanne_Jumatano_Alhamisi_Ijumaa_Jumamosi".split("_"),weekdaysShort:"Jpl_Jtat_Jnne_Jtan_Alh_Ijm_Jmos".split("_"),weekdaysMin:"J2_J3_J4_J5_Al_Ij_J1".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[leo saa] LT",nextDay:"[kesho saa] LT",nextWeek:"[wiki ijayo] dddd [saat] LT",lastDay:"[jana] LT",lastWeek:"[wiki iliyopita] dddd [saat] LT",sameElse:"L"},relativeTime:{future:"%s baadaye",past:"tokea %s",s:"hivi punde",ss:"sekunde %d",m:"dakika moja",mm:"dakika %d",h:"saa limoja",hh:"masaa %d",d:"siku moja",dd:"masiku %d",M:"mwezi mmoja",MM:"miezi %d",y:"mwaka mmoja",yy:"miaka %d"},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"௧",2:"௨",3:"௩",4:"௪",5:"௫",6:"௬",7:"௭",8:"௮",9:"௯",0:"௦"},n={"௧":"1","௨":"2","௩":"3","௪":"4","௫":"5","௬":"6","௭":"7","௮":"8","௯":"9","௦":"0"};e.defineLocale("ta",{months:"ஜனவரி_பிப்ரவரி_மார்ச்_ஏப்ரல்_மே_ஜூன்_ஜூலை_ஆகஸ்ட்_செப்டெம்பர்_அக்டோபர்_நவம்பர்_டிசம்பர்".split("_"),monthsShort:"ஜனவரி_பிப்ரவரி_மார்ச்_ஏப்ரல்_மே_ஜூன்_ஜூலை_ஆகஸ்ட்_செப்டெம்பர்_அக்டோபர்_நவம்பர்_டிசம்பர்".split("_"),weekdays:"ஞாயிற்றுக்கிழமை_திங்கட்கிழமை_செவ்வாய்கிழமை_புதன்கிழமை_வியாழக்கிழமை_வெள்ளிக்கிழமை_சனிக்கிழமை".split("_"),weekdaysShort:"ஞாயிறு_திங்கள்_செவ்வாய்_புதன்_வியாழன்_வெள்ளி_சனி".split("_"),weekdaysMin:"ஞா_தி_செ_பு_வி_வெ_ச".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, HH:mm",LLLL:"dddd, D MMMM YYYY, HH:mm"},calendar:{sameDay:"[இன்று] LT",nextDay:"[நாளை] LT",nextWeek:"dddd, LT",lastDay:"[நேற்று] LT",lastWeek:"[கடந்த வாரம்] dddd, LT",sameElse:"L"},relativeTime:{future:"%s இல்",past:"%s முன்",s:"ஒரு சில விநாடிகள்",ss:"%d விநாடிகள்",m:"ஒரு நிமிடம்",mm:"%d நிமிடங்கள்",h:"ஒரு மணி நேரம்",hh:"%d மணி நேரம்",d:"ஒரு நாள்",dd:"%d நாட்கள்",M:"ஒரு மாதம்",MM:"%d மாதங்கள்",y:"ஒரு வருடம்",yy:"%d ஆண்டுகள்"},dayOfMonthOrdinalParse:/\d{1,2}வது/,ordinal:function(e){return e+"வது"},preparse:function(e){return e.replace(/[௧௨௩௪௫௬௭௮௯௦]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/யாமம்|வைகறை|காலை|நண்பகல்|எற்பாடு|மாலை/,meridiem:function(e,t,n){return e<2?" யாமம்":e<6?" வைகறை":e<10?" காலை":e<14?" நண்பகல்":e<18?" எற்பாடு":e<22?" மாலை":" யாமம்"},meridiemHour:function(e,t){return 12===e&&(e=0),"யாமம்"===t?e<2?e:e+12:"வைகறை"===t||"காலை"===t?e:"நண்பகல்"===t&&e>=10?e:e+12},week:{dow:0,doy:6}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("te",{months:"జనవరి_ఫిబ్రవరి_మార్చి_ఏప్రిల్_మే_జూన్_జులై_ఆగస్టు_సెప్టెంబర్_అక్టోబర్_నవంబర్_డిసెంబర్".split("_"),monthsShort:"జన._ఫిబ్ర._మార్చి_ఏప్రి._మే_జూన్_జులై_ఆగ._సెప్._అక్టో._నవ._డిసె.".split("_"),monthsParseExact:!0,weekdays:"ఆదివారం_సోమవారం_మంగళవారం_బుధవారం_గురువారం_శుక్రవారం_శనివారం".split("_"),weekdaysShort:"ఆది_సోమ_మంగళ_బుధ_గురు_శుక్ర_శని".split("_"),weekdaysMin:"ఆ_సో_మం_బు_గు_శు_శ".split("_"),longDateFormat:{LT:"A h:mm",LTS:"A h:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm",LLLL:"dddd, D MMMM YYYY, A h:mm"},calendar:{sameDay:"[నేడు] LT",nextDay:"[రేపు] LT",nextWeek:"dddd, LT",lastDay:"[నిన్న] LT",lastWeek:"[గత] dddd, LT",sameElse:"L"},relativeTime:{future:"%s లో",past:"%s క్రితం",s:"కొన్ని క్షణాలు",ss:"%d సెకన్లు",m:"ఒక నిమిషం",mm:"%d నిమిషాలు",h:"ఒక గంట",hh:"%d గంటలు",d:"ఒక రోజు",dd:"%d రోజులు",M:"ఒక నెల",MM:"%d నెలలు",y:"ఒక సంవత్సరం",yy:"%d సంవత్సరాలు"},dayOfMonthOrdinalParse:/\d{1,2}వ/,ordinal:"%dవ",meridiemParse:/రాత్రి|ఉదయం|మధ్యాహ్నం|సాయంత్రం/,meridiemHour:function(e,t){return 12===e&&(e=0),"రాత్రి"===t?e<4?e:e+12:"ఉదయం"===t?e:"మధ్యాహ్నం"===t?e>=10?e:e+12:"సాయంత్రం"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"రాత్రి":e<10?"ఉదయం":e<17?"మధ్యాహ్నం":e<20?"సాయంత్రం":"రాత్రి"},week:{dow:0,doy:6}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("tet",{months:"Janeiru_Fevereiru_Marsu_Abril_Maiu_Juñu_Jullu_Agustu_Setembru_Outubru_Novembru_Dezembru".split("_"),monthsShort:"Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez".split("_"),weekdays:"Domingu_Segunda_Tersa_Kuarta_Kinta_Sesta_Sabadu".split("_"),weekdaysShort:"Dom_Seg_Ters_Kua_Kint_Sest_Sab".split("_"),weekdaysMin:"Do_Seg_Te_Ku_Ki_Ses_Sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Ohin iha] LT",nextDay:"[Aban iha] LT",nextWeek:"dddd [iha] LT",lastDay:"[Horiseik iha] LT",lastWeek:"dddd [semana kotuk] [iha] LT",sameElse:"L"},relativeTime:{future:"iha %s",past:"%s liuba",s:"minutu balun",ss:"minutu %d",m:"minutu ida",mm:"minutu %d",h:"oras ida",hh:"oras %d",d:"loron ida",dd:"loron %d",M:"fulan ida",MM:"fulan %d",y:"tinan ida",yy:"tinan %d"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10,n=1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+n},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={0:"-ум",1:"-ум",2:"-юм",3:"-юм",4:"-ум",5:"-ум",6:"-ум",7:"-ум",8:"-ум",9:"-ум",10:"-ум",12:"-ум",13:"-ум",20:"-ум",30:"-юм",40:"-ум",50:"-ум",60:"-ум",70:"-ум",80:"-ум",90:"-ум",100:"-ум"};e.defineLocale("tg",{months:"январ_феврал_март_апрел_май_июн_июл_август_сентябр_октябр_ноябр_декабр".split("_"),monthsShort:"янв_фев_мар_апр_май_июн_июл_авг_сен_окт_ноя_дек".split("_"),weekdays:"якшанбе_душанбе_сешанбе_чоршанбе_панҷшанбе_ҷумъа_шанбе".split("_"),weekdaysShort:"яшб_дшб_сшб_чшб_пшб_ҷум_шнб".split("_"),weekdaysMin:"яш_дш_сш_чш_пш_ҷм_шб".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Имрӯз соати] LT",nextDay:"[Пагоҳ соати] LT",lastDay:"[Дирӯз соати] LT",nextWeek:"dddd[и] [ҳафтаи оянда соати] LT",lastWeek:"dddd[и] [ҳафтаи гузашта соати] LT",sameElse:"L"},relativeTime:{future:"баъди %s",past:"%s пеш",s:"якчанд сония",m:"як дақиқа",mm:"%d дақиқа",h:"як соат",hh:"%d соат",d:"як рӯз",dd:"%d рӯз",M:"як моҳ",MM:"%d моҳ",y:"як сол",yy:"%d сол"},meridiemParse:/шаб|субҳ|рӯз|бегоҳ/,meridiemHour:function(e,t){return 12===e&&(e=0),"шаб"===t?e<4?e:e+12:"субҳ"===t?e:"рӯз"===t?e>=11?e:e+12:"бегоҳ"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"шаб":e<11?"субҳ":e<16?"рӯз":e<19?"бегоҳ":"шаб"},dayOfMonthOrdinalParse:/\d{1,2}-(ум|юм)/,ordinal:function(e){var n=e%10,r=e>=100?100:null;return e+(t[e]||t[n]||t[r])},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("th",{months:"มกราคม_กุมภาพันธ์_มีนาคม_เมษายน_พฤษภาคม_มิถุนายน_กรกฎาคม_สิงหาคม_กันยายน_ตุลาคม_พฤศจิกายน_ธันวาคม".split("_"),monthsShort:"ม.ค._ก.พ._มี.ค._เม.ย._พ.ค._มิ.ย._ก.ค._ส.ค._ก.ย._ต.ค._พ.ย._ธ.ค.".split("_"),monthsParseExact:!0,weekdays:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัสบดี_ศุกร์_เสาร์".split("_"),weekdaysShort:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัส_ศุกร์_เสาร์".split("_"),weekdaysMin:"อา._จ._อ._พ._พฤ._ศ._ส.".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY เวลา H:mm",LLLL:"วันddddที่ D MMMM YYYY เวลา H:mm"},meridiemParse:/ก่อนเที่ยง|หลังเที่ยง/,isPM:function(e){return"หลังเที่ยง"===e},meridiem:function(e,t,n){return e<12?"ก่อนเที่ยง":"หลังเที่ยง"},calendar:{sameDay:"[วันนี้ เวลา] LT",nextDay:"[พรุ่งนี้ เวลา] LT",nextWeek:"dddd[หน้า เวลา] LT",lastDay:"[เมื่อวานนี้ เวลา] LT",lastWeek:"[วัน]dddd[ที่แล้ว เวลา] LT",sameElse:"L"},relativeTime:{future:"อีก %s",past:"%sที่แล้ว",s:"ไม่กี่วินาที",ss:"%d วินาที",m:"1 นาที",mm:"%d นาที",h:"1 ชั่วโมง",hh:"%d ชั่วโมง",d:"1 วัน",dd:"%d วัน",M:"1 เดือน",MM:"%d เดือน",y:"1 ปี",yy:"%d ปี"}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("tl-ph",{months:"Enero_Pebrero_Marso_Abril_Mayo_Hunyo_Hulyo_Agosto_Setyembre_Oktubre_Nobyembre_Disyembre".split("_"),monthsShort:"Ene_Peb_Mar_Abr_May_Hun_Hul_Ago_Set_Okt_Nob_Dis".split("_"),weekdays:"Linggo_Lunes_Martes_Miyerkules_Huwebes_Biyernes_Sabado".split("_"),weekdaysShort:"Lin_Lun_Mar_Miy_Huw_Biy_Sab".split("_"),weekdaysMin:"Li_Lu_Ma_Mi_Hu_Bi_Sab".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"MM/D/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY HH:mm",LLLL:"dddd, MMMM DD, YYYY HH:mm"},calendar:{sameDay:"LT [ngayong araw]",nextDay:"[Bukas ng] LT",nextWeek:"LT [sa susunod na] dddd",lastDay:"LT [kahapon]",lastWeek:"LT [noong nakaraang] dddd",sameElse:"L"},relativeTime:{future:"sa loob ng %s",past:"%s ang nakalipas",s:"ilang segundo",ss:"%d segundo",m:"isang minuto",mm:"%d minuto",h:"isang oras",hh:"%d oras",d:"isang araw",dd:"%d araw",M:"isang buwan",MM:"%d buwan",y:"isang taon",yy:"%d taon"},dayOfMonthOrdinalParse:/\d{1,2}/,ordinal:function(e){return e},week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t="pagh_wa’_cha’_wej_loS_vagh_jav_Soch_chorgh_Hut".split("_");function n(e,n,r,a){var o=function(e){var n=Math.floor(e%1e3/100),r=Math.floor(e%100/10),a=e%10,o="";return n>0&&(o+=t[n]+"vatlh"),r>0&&(o+=(""!==o?" ":"")+t[r]+"maH"),a>0&&(o+=(""!==o?" ":"")+t[a]),""===o?"pagh":o}(e);switch(r){case"ss":return o+" lup";case"mm":return o+" tup";case"hh":return o+" rep";case"dd":return o+" jaj";case"MM":return o+" jar";case"yy":return o+" DIS"}}e.defineLocale("tlh",{months:"tera’ jar wa’_tera’ jar cha’_tera’ jar wej_tera’ jar loS_tera’ jar vagh_tera’ jar jav_tera’ jar Soch_tera’ jar chorgh_tera’ jar Hut_tera’ jar wa’maH_tera’ jar wa’maH wa’_tera’ jar wa’maH cha’".split("_"),monthsShort:"jar wa’_jar cha’_jar wej_jar loS_jar vagh_jar jav_jar Soch_jar chorgh_jar Hut_jar wa’maH_jar wa’maH wa’_jar wa’maH cha’".split("_"),monthsParseExact:!0,weekdays:"lojmItjaj_DaSjaj_povjaj_ghItlhjaj_loghjaj_buqjaj_ghInjaj".split("_"),weekdaysShort:"lojmItjaj_DaSjaj_povjaj_ghItlhjaj_loghjaj_buqjaj_ghInjaj".split("_"),weekdaysMin:"lojmItjaj_DaSjaj_povjaj_ghItlhjaj_loghjaj_buqjaj_ghInjaj".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[DaHjaj] LT",nextDay:"[wa’leS] LT",nextWeek:"LLL",lastDay:"[wa’Hu’] LT",lastWeek:"LLL",sameElse:"L"},relativeTime:{future:function(e){var t=e;return t=-1!==e.indexOf("jaj")?t.slice(0,-3)+"leS":-1!==e.indexOf("jar")?t.slice(0,-3)+"waQ":-1!==e.indexOf("DIS")?t.slice(0,-3)+"nem":t+" pIq"},past:function(e){var t=e;return t=-1!==e.indexOf("jaj")?t.slice(0,-3)+"Hu’":-1!==e.indexOf("jar")?t.slice(0,-3)+"wen":-1!==e.indexOf("DIS")?t.slice(0,-3)+"ben":t+" ret"},s:"puS lup",ss:n,m:"wa’ tup",mm:n,h:"wa’ rep",hh:n,d:"wa’ jaj",dd:n,M:"wa’ jar",MM:n,y:"wa’ DIS",yy:n},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";var t={1:"'inci",5:"'inci",8:"'inci",70:"'inci",80:"'inci",2:"'nci",7:"'nci",20:"'nci",50:"'nci",3:"'üncü",4:"'üncü",100:"'üncü",6:"'ncı",9:"'uncu",10:"'uncu",30:"'uncu",60:"'ıncı",90:"'ıncı"};e.defineLocale("tr",{months:"Ocak_Şubat_Mart_Nisan_Mayıs_Haziran_Temmuz_Ağustos_Eylül_Ekim_Kasım_Aralık".split("_"),monthsShort:"Oca_Şub_Mar_Nis_May_Haz_Tem_Ağu_Eyl_Eki_Kas_Ara".split("_"),weekdays:"Pazar_Pazartesi_Salı_Çarşamba_Perşembe_Cuma_Cumartesi".split("_"),weekdaysShort:"Paz_Pts_Sal_Çar_Per_Cum_Cts".split("_"),weekdaysMin:"Pz_Pt_Sa_Ça_Pe_Cu_Ct".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[bugün saat] LT",nextDay:"[yarın saat] LT",nextWeek:"[gelecek] dddd [saat] LT",lastDay:"[dün] LT",lastWeek:"[geçen] dddd [saat] LT",sameElse:"L"},relativeTime:{future:"%s sonra",past:"%s önce",s:"birkaç saniye",ss:"%d saniye",m:"bir dakika",mm:"%d dakika",h:"bir saat",hh:"%d saat",d:"bir gün",dd:"%d gün",M:"bir ay",MM:"%d ay",y:"bir yıl",yy:"%d yıl"},ordinal:function(e,n){switch(n){case"d":case"D":case"Do":case"DD":return e;default:if(0===e)return e+"'ıncı";var r=e%10,a=e%100-r,o=e>=100?100:null;return e+(t[r]||t[a]||t[o])}},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n,r){var a={s:["viensas secunds","'iensas secunds"],ss:[e+" secunds",e+" secunds"],m:["'n míut","'iens míut"],mm:[e+" míuts",e+" míuts"],h:["'n þora","'iensa þora"],hh:[e+" þoras",e+" þoras"],d:["'n ziua","'iensa ziua"],dd:[e+" ziuas",e+" ziuas"],M:["'n mes","'iens mes"],MM:[e+" mesen",e+" mesen"],y:["'n ar","'iens ar"],yy:[e+" ars",e+" ars"]};return r?a[n][0]:t?a[n][0]:a[n][1]}e.defineLocale("tzl",{months:"Januar_Fevraglh_Març_Avrïu_Mai_Gün_Julia_Guscht_Setemvar_Listopäts_Noemvar_Zecemvar".split("_"),monthsShort:"Jan_Fev_Mar_Avr_Mai_Gün_Jul_Gus_Set_Lis_Noe_Zec".split("_"),weekdays:"Súladi_Lúneçi_Maitzi_Márcuri_Xhúadi_Viénerçi_Sáturi".split("_"),weekdaysShort:"Súl_Lún_Mai_Már_Xhú_Vié_Sát".split("_"),weekdaysMin:"Sú_Lú_Ma_Má_Xh_Vi_Sá".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD.MM.YYYY",LL:"D. MMMM [dallas] YYYY",LLL:"D. MMMM [dallas] YYYY HH.mm",LLLL:"dddd, [li] D. MMMM [dallas] YYYY HH.mm"},meridiemParse:/d\'o|d\'a/i,isPM:function(e){return"d'o"===e.toLowerCase()},meridiem:function(e,t,n){return e>11?n?"d'o":"D'O":n?"d'a":"D'A"},calendar:{sameDay:"[oxhi à] LT",nextDay:"[demà à] LT",nextWeek:"dddd [à] LT",lastDay:"[ieiri à] LT",lastWeek:"[sür el] dddd [lasteu à] LT",sameElse:"L"},relativeTime:{future:"osprei %s",past:"ja%s",s:t,ss:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("tzm",{months:"ⵉⵏⵏⴰⵢⵔ_ⴱⵕⴰⵢⵕ_ⵎⴰⵕⵚ_ⵉⴱⵔⵉⵔ_ⵎⴰⵢⵢⵓ_ⵢⵓⵏⵢⵓ_ⵢⵓⵍⵢⵓⵣ_ⵖⵓⵛⵜ_ⵛⵓⵜⴰⵏⴱⵉⵔ_ⴽⵟⵓⴱⵕ_ⵏⵓⵡⴰⵏⴱⵉⵔ_ⴷⵓⵊⵏⴱⵉⵔ".split("_"),monthsShort:"ⵉⵏⵏⴰⵢⵔ_ⴱⵕⴰⵢⵕ_ⵎⴰⵕⵚ_ⵉⴱⵔⵉⵔ_ⵎⴰⵢⵢⵓ_ⵢⵓⵏⵢⵓ_ⵢⵓⵍⵢⵓⵣ_ⵖⵓⵛⵜ_ⵛⵓⵜⴰⵏⴱⵉⵔ_ⴽⵟⵓⴱⵕ_ⵏⵓⵡⴰⵏⴱⵉⵔ_ⴷⵓⵊⵏⴱⵉⵔ".split("_"),weekdays:"ⴰⵙⴰⵎⴰⵙ_ⴰⵢⵏⴰⵙ_ⴰⵙⵉⵏⴰⵙ_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ".split("_"),weekdaysShort:"ⴰⵙⴰⵎⴰⵙ_ⴰⵢⵏⴰⵙ_ⴰⵙⵉⵏⴰⵙ_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ".split("_"),weekdaysMin:"ⴰⵙⴰⵎⴰⵙ_ⴰⵢⵏⴰⵙ_ⴰⵙⵉⵏⴰⵙ_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[ⴰⵙⴷⵅ ⴴ] LT",nextDay:"[ⴰⵙⴽⴰ ⴴ] LT",nextWeek:"dddd [ⴴ] LT",lastDay:"[ⴰⵚⴰⵏⵜ ⴴ] LT",lastWeek:"dddd [ⴴ] LT",sameElse:"L"},relativeTime:{future:"ⴷⴰⴷⵅ ⵙ ⵢⴰⵏ %s",past:"ⵢⴰⵏ %s",s:"ⵉⵎⵉⴽ",ss:"%d ⵉⵎⵉⴽ",m:"ⵎⵉⵏⵓⴺ",mm:"%d ⵎⵉⵏⵓⴺ",h:"ⵙⴰⵄⴰ",hh:"%d ⵜⴰⵙⵙⴰⵄⵉⵏ",d:"ⴰⵙⵙ",dd:"%d oⵙⵙⴰⵏ",M:"ⴰⵢoⵓⵔ",MM:"%d ⵉⵢⵢⵉⵔⵏ",y:"ⴰⵙⴳⴰⵙ",yy:"%d ⵉⵙⴳⴰⵙⵏ"},week:{dow:6,doy:12}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("tzm-latn",{months:"innayr_brˤayrˤ_marˤsˤ_ibrir_mayyw_ywnyw_ywlywz_ɣwšt_šwtanbir_ktˤwbrˤ_nwwanbir_dwjnbir".split("_"),monthsShort:"innayr_brˤayrˤ_marˤsˤ_ibrir_mayyw_ywnyw_ywlywz_ɣwšt_šwtanbir_ktˤwbrˤ_nwwanbir_dwjnbir".split("_"),weekdays:"asamas_aynas_asinas_akras_akwas_asimwas_asiḍyas".split("_"),weekdaysShort:"asamas_aynas_asinas_akras_akwas_asimwas_asiḍyas".split("_"),weekdaysMin:"asamas_aynas_asinas_akras_akwas_asimwas_asiḍyas".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[asdkh g] LT",nextDay:"[aska g] LT",nextWeek:"dddd [g] LT",lastDay:"[assant g] LT",lastWeek:"dddd [g] LT",sameElse:"L"},relativeTime:{future:"dadkh s yan %s",past:"yan %s",s:"imik",ss:"%d imik",m:"minuḍ",mm:"%d minuḍ",h:"saɛa",hh:"%d tassaɛin",d:"ass",dd:"%d ossan",M:"ayowr",MM:"%d iyyirn",y:"asgas",yy:"%d isgasn"},week:{dow:6,doy:12}})}(n(8))},function(e,t,n){!function(e){"use strict";e.defineLocale("ug-cn",{months:"يانۋار_فېۋرال_مارت_ئاپرېل_ماي_ئىيۇن_ئىيۇل_ئاۋغۇست_سېنتەبىر_ئۆكتەبىر_نويابىر_دېكابىر".split("_"),monthsShort:"يانۋار_فېۋرال_مارت_ئاپرېل_ماي_ئىيۇن_ئىيۇل_ئاۋغۇست_سېنتەبىر_ئۆكتەبىر_نويابىر_دېكابىر".split("_"),weekdays:"يەكشەنبە_دۈشەنبە_سەيشەنبە_چارشەنبە_پەيشەنبە_جۈمە_شەنبە".split("_"),weekdaysShort:"يە_دۈ_سە_چا_پە_جۈ_شە".split("_"),weekdaysMin:"يە_دۈ_سە_چا_پە_جۈ_شە".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"YYYY-يىلىM-ئاينىڭD-كۈنى",LLL:"YYYY-يىلىM-ئاينىڭD-كۈنى، HH:mm",LLLL:"dddd، YYYY-يىلىM-ئاينىڭD-كۈنى، HH:mm"},meridiemParse:/يېرىم كېچە|سەھەر|چۈشتىن بۇرۇن|چۈش|چۈشتىن كېيىن|كەچ/,meridiemHour:function(e,t){return 12===e&&(e=0),"يېرىم كېچە"===t||"سەھەر"===t||"چۈشتىن بۇرۇن"===t?e:"چۈشتىن كېيىن"===t||"كەچ"===t?e+12:e>=11?e:e+12},meridiem:function(e,t,n){var r=100*e+t;return r<600?"يېرىم كېچە":r<900?"سەھەر":r<1130?"چۈشتىن بۇرۇن":r<1230?"چۈش":r<1800?"چۈشتىن كېيىن":"كەچ"},calendar:{sameDay:"[بۈگۈن سائەت] LT",nextDay:"[ئەتە سائەت] LT",nextWeek:"[كېلەركى] dddd [سائەت] LT",lastDay:"[تۆنۈگۈن] LT",lastWeek:"[ئالدىنقى] dddd [سائەت] LT",sameElse:"L"},relativeTime:{future:"%s كېيىن",past:"%s بۇرۇن",s:"نەچچە سېكونت",ss:"%d سېكونت",m:"بىر مىنۇت",mm:"%d مىنۇت",h:"بىر سائەت",hh:"%d سائەت",d:"بىر كۈن",dd:"%d كۈن",M:"بىر ئاي",MM:"%d ئاي",y:"بىر يىل",yy:"%d يىل"},dayOfMonthOrdinalParse:/\d{1,2}(-كۈنى|-ئاي|-ھەپتە)/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"-كۈنى";case"w":case"W":return e+"-ھەپتە";default:return e}},preparse:function(e){return e.replace(/،/g,",")},postformat:function(e){return e.replace(/,/g,"،")},week:{dow:1,doy:7}})}(n(8))},function(e,t,n){!function(e){"use strict";function t(e,t,n){var r,a,o={ss:t?"секунда_секунди_секунд":"секунду_секунди_секунд",mm:t?"хвилина_хвилини_хвилин":"хвилину_хвилини_хвилин",hh:t?"година_години_годин":"годину_години_годин",dd:"день_дні_днів",MM:"місяць_місяці_місяців",yy:"рік_роки_років"};return"m"===n?t?"хвилина":"хвилину":"h"===n?t?"година":"годину":e+" "+(r=+e,a=o[n].split("_"),r%10==1&&r%100!=11?a[0]:r%10>=2&&r%10<=4&&(r%100<10||r%100>=20)?a[1]:a[2])}function n(e){return function(){return e+"о"+(11===this.hours()?"б":"")+"] LT"}}e.defineLocale("uk",{months:{format:"січня_лютого_березня_квітня_травня_червня_липня_серпня_вересня_жовтня_листопада_грудня".split("_"),standalone:"січень_лютий_березень_квітень_травень_червень_липень_серпень_вересень_жовтень_листопад_грудень".split("_")},monthsShort:"січ_лют_бер_квіт_трав_черв_лип_серп_вер_жовт_лист_груд".split("_"),weekdays:function(e,t){var n={nominative:"неділя_понеділок_вівторок_середа_четвер_п’ятниця_субота".split("_"),accusative:"неділю_понеділок_вівторок_середу_четвер_п’ятницю_суботу".split("_"),genitive:"неділі_понеділка_вівторка_середи_четверга_п’ятниці_суботи".split("_")};if(!0===e)return n.nominative.slice(1,7).concat(n.nominative.slice(0,1));if(!e)return n.nominative;var r=/(\[[ВвУу]\]) ?dddd/.test(t)?"accusative":/\[?(?:минулої|наступної)? ?\] ?dddd/.test(t)?"genitive":"nominative";return n[r][e.day()]},weekdaysShort:"нд_пн_вт_ср_чт_пт_сб".split("_"),weekdaysMin:"нд_пн_вт_ср_чт_пт_сб".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm