@foxy.io/elements 1.45.0 → 1.46.0-beta.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (330) hide show
  1. package/dist/cdn/foxy-access-recovery-form.js +1 -1
  2. package/dist/cdn/foxy-address-card.js +1 -1
  3. package/dist/cdn/foxy-address-form.js +1 -1
  4. package/dist/cdn/foxy-admin-subscription-card.js +1 -1
  5. package/dist/cdn/foxy-admin-subscription-form.js +1 -1
  6. package/dist/cdn/foxy-admin-transaction-card.js +1 -0
  7. package/dist/cdn/foxy-api-browser.js +1 -1
  8. package/dist/cdn/foxy-applied-coupon-code-card.js +1 -1
  9. package/dist/cdn/foxy-applied-coupon-code-form.js +1 -1
  10. package/dist/cdn/foxy-applied-tax-card.js +1 -1
  11. package/dist/cdn/foxy-attribute-card.js +1 -1
  12. package/dist/cdn/foxy-attribute-form.js +1 -1
  13. package/dist/cdn/foxy-billing-address-card.js +1 -1
  14. package/dist/cdn/foxy-cancellation-form.js +1 -1
  15. package/dist/cdn/foxy-cart-card.js +1 -1
  16. package/dist/cdn/foxy-cart-form.js +2 -2
  17. package/dist/cdn/foxy-client-card.js +1 -1
  18. package/dist/cdn/foxy-client-form.js +1 -1
  19. package/dist/cdn/foxy-collection-page.js +1 -1
  20. package/dist/cdn/foxy-collection-pages.js +1 -1
  21. package/dist/cdn/foxy-copy-to-clipboard.js +1 -1
  22. package/dist/cdn/foxy-coupon-card.js +1 -1
  23. package/dist/cdn/foxy-coupon-code-card.js +1 -1
  24. package/dist/cdn/foxy-coupon-code-form.js +1 -1
  25. package/dist/cdn/foxy-coupon-codes-form.js +1 -1
  26. package/dist/cdn/foxy-coupon-detail-card.js +1 -1
  27. package/dist/cdn/foxy-coupon-form.js +1 -1
  28. package/dist/cdn/foxy-custom-field-card.js +1 -1
  29. package/dist/cdn/foxy-custom-field-form.js +1 -1
  30. package/dist/cdn/foxy-customer-api.js +1 -1
  31. package/dist/cdn/foxy-customer-card.js +1 -1
  32. package/dist/cdn/foxy-customer-form.js +1 -1
  33. package/dist/cdn/foxy-customer-portal-settings-form.js +1 -1
  34. package/dist/cdn/foxy-customer-portal-settings.js +1 -1
  35. package/dist/cdn/foxy-customer-portal.js +11 -11
  36. package/dist/cdn/foxy-customer.js +1 -1
  37. package/dist/cdn/foxy-customers-table.js +1 -1
  38. package/dist/cdn/foxy-discount-builder.js +1 -1
  39. package/dist/cdn/foxy-discount-card.js +1 -1
  40. package/dist/cdn/foxy-discount-detail-card.js +1 -1
  41. package/dist/cdn/foxy-donation.js +1 -1
  42. package/dist/cdn/foxy-downloadable-card.js +1 -1
  43. package/dist/cdn/foxy-downloadable-form.js +1 -1
  44. package/dist/cdn/foxy-email-template-card.js +1 -1
  45. package/dist/cdn/foxy-email-template-form.js +1 -1
  46. package/dist/cdn/foxy-error-entry-card.js +1 -1
  47. package/dist/cdn/foxy-experimental-add-to-cart-builder.js +1 -1
  48. package/dist/cdn/foxy-filter-attribute-card.js +1 -1
  49. package/dist/cdn/foxy-filter-attribute-form.js +1 -1
  50. package/dist/cdn/foxy-form-dialog.js +1 -1
  51. package/dist/cdn/foxy-generate-codes-form.js +1 -1
  52. package/dist/cdn/foxy-gift-card-card.js +1 -1
  53. package/dist/cdn/foxy-gift-card-code-card.js +1 -1
  54. package/dist/cdn/foxy-gift-card-code-form.js +1 -1
  55. package/dist/cdn/foxy-gift-card-code-log-card.js +1 -1
  56. package/dist/cdn/foxy-gift-card-codes-form.js +1 -1
  57. package/dist/cdn/foxy-gift-card-form.js +1 -1
  58. package/dist/cdn/foxy-i18n-editor.js +1 -1
  59. package/dist/cdn/foxy-i18n.js +1 -1
  60. package/dist/cdn/foxy-integration-card.js +1 -1
  61. package/dist/cdn/foxy-integration-form.js +1 -1
  62. package/dist/cdn/foxy-item-card.js +1 -1
  63. package/dist/cdn/foxy-item-category-card.js +1 -1
  64. package/dist/cdn/foxy-item-category-form.js +1 -1
  65. package/dist/cdn/foxy-item-form.js +1 -1
  66. package/dist/cdn/foxy-item-option-card.js +1 -1
  67. package/dist/cdn/foxy-item-option-form.js +1 -1
  68. package/dist/cdn/foxy-items-form.js +1 -1
  69. package/dist/cdn/foxy-native-integration-card.js +1 -1
  70. package/dist/cdn/foxy-native-integration-form.js +1 -1
  71. package/dist/cdn/foxy-nucleon-element.js +1 -1
  72. package/dist/cdn/foxy-pagination.js +1 -1
  73. package/dist/cdn/foxy-passkey-card.js +1 -1
  74. package/dist/cdn/foxy-passkey-form.js +1 -1
  75. package/dist/cdn/foxy-payment-card-embed.js +1 -1
  76. package/dist/cdn/foxy-payment-card.js +1 -1
  77. package/dist/cdn/foxy-payment-method-card.js +1 -1
  78. package/dist/cdn/foxy-payments-api-fraud-protection-card.js +1 -1
  79. package/dist/cdn/foxy-payments-api-fraud-protection-form.js +1 -1
  80. package/dist/cdn/foxy-payments-api-payment-method-card.js +1 -1
  81. package/dist/cdn/foxy-payments-api-payment-method-form.js +1 -1
  82. package/dist/cdn/foxy-payments-api-payment-preset-card.js +1 -1
  83. package/dist/cdn/foxy-payments-api-payment-preset-form.js +1 -1
  84. package/dist/cdn/foxy-payments-api.js +1 -1
  85. package/dist/cdn/foxy-query-builder.js +1 -1
  86. package/dist/cdn/foxy-report-form.js +1 -1
  87. package/dist/cdn/foxy-reports-table.js +1 -1
  88. package/dist/cdn/foxy-shipment-card.js +1 -1
  89. package/dist/cdn/foxy-shipping-container-card.js +1 -1
  90. package/dist/cdn/foxy-shipping-drop-type-card.js +1 -1
  91. package/dist/cdn/foxy-shipping-method-card.js +1 -1
  92. package/dist/cdn/foxy-shipping-service-card.js +1 -1
  93. package/dist/cdn/foxy-sign-in-form.js +1 -1
  94. package/dist/cdn/foxy-spinner.js +1 -1
  95. package/dist/cdn/foxy-store-card.js +1 -1
  96. package/dist/cdn/foxy-store-form.js +1 -1
  97. package/dist/cdn/foxy-store-shipping-method-form.js +1 -1
  98. package/dist/cdn/foxy-store-transaction-folder-card.js +1 -0
  99. package/dist/cdn/foxy-store-transaction-folder-form.js +1 -0
  100. package/dist/cdn/foxy-subscription-card.js +1 -1
  101. package/dist/cdn/foxy-subscription-form.js +1 -1
  102. package/dist/cdn/foxy-subscription-settings-form.js +1 -1
  103. package/dist/cdn/foxy-subscriptions-table.js +1 -1
  104. package/dist/cdn/foxy-swipe-actions.js +1 -1
  105. package/dist/cdn/foxy-table.js +1 -1
  106. package/dist/cdn/foxy-tax-card.js +1 -1
  107. package/dist/cdn/foxy-tax-form.js +1 -1
  108. package/dist/cdn/foxy-template-config-form.js +1 -1
  109. package/dist/cdn/foxy-template-form.js +1 -1
  110. package/dist/cdn/foxy-template-set-card.js +1 -1
  111. package/dist/cdn/foxy-template-set-form.js +1 -1
  112. package/dist/cdn/foxy-transaction-card.js +1 -1
  113. package/dist/cdn/foxy-transaction.js +1 -1
  114. package/dist/cdn/foxy-transactions-table.js +1 -1
  115. package/dist/cdn/foxy-update-payment-method-form.js +1 -1
  116. package/dist/cdn/foxy-user-card.js +1 -1
  117. package/dist/cdn/foxy-user-form.js +1 -1
  118. package/dist/cdn/foxy-user-invitation-card.js +1 -1
  119. package/dist/cdn/foxy-user-invitation-form.js +1 -1
  120. package/dist/cdn/foxy-users-table.js +1 -1
  121. package/dist/cdn/foxy-webhook-card.js +1 -1
  122. package/dist/cdn/foxy-webhook-form.js +1 -1
  123. package/dist/cdn/foxy-webhook-log-card.js +1 -1
  124. package/dist/cdn/foxy-webhook-status-card.js +1 -1
  125. package/dist/cdn/{shared-6c25eb72.js → shared-0557539b.js} +1 -1
  126. package/dist/cdn/{shared-1e14a3fe.js → shared-0b8768db.js} +1 -1
  127. package/dist/cdn/{shared-cc0d9412.js → shared-0db4e843.js} +3 -3
  128. package/dist/cdn/{shared-e1e4d8f5.js → shared-0e19bda5.js} +1 -1
  129. package/dist/cdn/{shared-85ed835a.js → shared-0e25ac65.js} +1 -1
  130. package/dist/cdn/{shared-4e1bff30.js → shared-0e5484c2.js} +1 -1
  131. package/dist/cdn/{shared-7dc40542.js → shared-11de7969.js} +1 -1
  132. package/dist/cdn/{shared-fd5ff448.js → shared-14cc889b.js} +1 -1
  133. package/dist/cdn/{shared-f9d1baff.js → shared-15a75e70.js} +1 -1
  134. package/dist/cdn/{shared-946a7af6.js → shared-16776ac6.js} +1 -1
  135. package/dist/cdn/{shared-c6b1b119.js → shared-18dc7a8a.js} +1 -1
  136. package/dist/cdn/{shared-c929504f.js → shared-1c985317.js} +1 -1
  137. package/dist/cdn/{shared-f1e48b0e.js → shared-2111aa44.js} +1 -1
  138. package/dist/cdn/shared-257dd725.js +1 -0
  139. package/dist/cdn/{shared-a268320e.js → shared-27c16d99.js} +1 -1
  140. package/dist/cdn/{shared-4cc42648.js → shared-28ceb7f7.js} +1 -1
  141. package/dist/cdn/{shared-a1297ca4.js → shared-2df3c589.js} +1 -1
  142. package/dist/cdn/{shared-85668fe8.js → shared-2f8d04dc.js} +1 -1
  143. package/dist/cdn/{shared-e54135f0.js → shared-32b2d003.js} +1 -1
  144. package/dist/cdn/{shared-005168e0.js → shared-34a87829.js} +1 -1
  145. package/dist/cdn/{shared-5963a49e.js → shared-360196ad.js} +1 -1
  146. package/dist/cdn/shared-3d353eb8.js +1 -0
  147. package/dist/cdn/{shared-3c94ab84.js → shared-4158f91e.js} +1 -1
  148. package/dist/cdn/{shared-809d503c.js → shared-4194ffe7.js} +1 -1
  149. package/dist/cdn/{shared-c782b9fa.js → shared-41c9c53f.js} +1 -1
  150. package/dist/cdn/{shared-8340f3ab.js → shared-4498a367.js} +1 -1
  151. package/dist/cdn/shared-47f3f5f5.js +29 -0
  152. package/dist/cdn/{shared-788173f2.js → shared-4eb52fc7.js} +1 -1
  153. package/dist/cdn/{shared-f8519b17.js → shared-57e94234.js} +1 -1
  154. package/dist/cdn/{shared-a704aaa4.js → shared-58add5b4.js} +1 -1
  155. package/dist/cdn/{shared-e502a7be.js → shared-59128d82.js} +1 -1
  156. package/dist/cdn/{shared-433eea12.js → shared-5a469962.js} +1 -1
  157. package/dist/cdn/shared-5c8931a0.js +1 -0
  158. package/dist/cdn/{shared-d3414cf0.js → shared-64231b81.js} +1 -1
  159. package/dist/cdn/{shared-64e243c4.js → shared-66278c21.js} +1 -1
  160. package/dist/cdn/shared-6740e365.js +1 -0
  161. package/dist/cdn/{shared-65b2760f.js → shared-69c98b7b.js} +1 -1
  162. package/dist/cdn/{shared-b5a0d106.js → shared-6bf89411.js} +1 -1
  163. package/dist/cdn/{shared-50f8f2bd.js → shared-6f071960.js} +1 -1
  164. package/dist/cdn/{shared-138959d7.js → shared-6f90d987.js} +1 -1
  165. package/dist/cdn/{shared-e4792d4a.js → shared-730acf1d.js} +1 -1
  166. package/dist/cdn/{shared-1ae16c80.js → shared-742640c2.js} +1 -1
  167. package/dist/cdn/shared-791b4510.js +1 -0
  168. package/dist/cdn/{shared-3b4148ad.js → shared-7f7d6ceb.js} +1 -1
  169. package/dist/cdn/{shared-be30b940.js → shared-803be1e4.js} +1 -1
  170. package/dist/cdn/{shared-2d1b1ab2.js → shared-845f968f.js} +1 -1
  171. package/dist/cdn/shared-8498f274.js +1 -0
  172. package/dist/cdn/{shared-bea6e6a7.js → shared-84e97597.js} +1 -1
  173. package/dist/cdn/{shared-597193f7.js → shared-8df4ab18.js} +1 -1
  174. package/dist/cdn/{shared-7fec42f2.js → shared-8f9014ff.js} +1 -1
  175. package/dist/cdn/{shared-0ea750af.js → shared-930e68b7.js} +1 -1
  176. package/dist/cdn/{shared-d6a0954b.js → shared-9496e995.js} +1 -1
  177. package/dist/cdn/{shared-0fb0732a.js → shared-97fac71c.js} +1 -1
  178. package/dist/cdn/shared-9b138652.js +1 -0
  179. package/dist/cdn/{shared-c5c123c5.js → shared-9e0b104a.js} +1 -1
  180. package/dist/cdn/{shared-21a945fd.js → shared-a08e5a5f.js} +5 -5
  181. package/dist/cdn/shared-a449033a.js +1 -0
  182. package/dist/cdn/{shared-3615b419.js → shared-a6ddec3d.js} +1 -1
  183. package/dist/cdn/{shared-e7a2b31d.js → shared-b01c3b62.js} +1 -1
  184. package/dist/cdn/{shared-5b0c206b.js → shared-b2cbe727.js} +1 -1
  185. package/dist/cdn/{shared-529a82a3.js → shared-b3fe8c63.js} +1 -1
  186. package/dist/cdn/{shared-51376cac.js → shared-bdc981e3.js} +1 -1
  187. package/dist/cdn/{shared-1091aa45.js → shared-be2ce0e6.js} +1 -1
  188. package/dist/cdn/{shared-937e58bf.js → shared-bf8d95b9.js} +1 -1
  189. package/dist/cdn/{shared-85feff39.js → shared-c5a44ef2.js} +1 -1
  190. package/dist/cdn/shared-c7796413.js +1 -0
  191. package/dist/cdn/{shared-12973e93.js → shared-c84333db.js} +1 -1
  192. package/dist/cdn/{shared-5380e27d.js → shared-d46230dc.js} +1 -1
  193. package/dist/cdn/{shared-9e8344bf.js → shared-d4b77609.js} +1 -1
  194. package/dist/cdn/{shared-7d15992f.js → shared-d9378323.js} +1 -1
  195. package/dist/cdn/{shared-37869bac.js → shared-da4f9115.js} +1 -1
  196. package/dist/cdn/shared-e2d5673b.js +1 -0
  197. package/dist/cdn/{shared-636d6e33.js → shared-e41960a0.js} +1 -1
  198. package/dist/cdn/{shared-278b8790.js → shared-e55c8dc4.js} +1 -1
  199. package/dist/cdn/{shared-5bcf861e.js → shared-eb49be2e.js} +1 -1
  200. package/dist/cdn/{shared-95d34ae8.js → shared-f2a7eb85.js} +5 -5
  201. package/dist/cdn/{shared-df7d368c.js → shared-fb859ece.js} +1 -1
  202. package/dist/cdn/shared-fc155659.js +1 -0
  203. package/dist/cdn/translations/admin-subscription-form/en.json +6 -6
  204. package/dist/cdn/translations/admin-transaction-card/en.json +35 -0
  205. package/dist/cdn/translations/coupon-code-form/en.json +6 -6
  206. package/dist/cdn/translations/store-transaction-folder-card/en.json +8 -0
  207. package/dist/cdn/translations/store-transaction-folder-form/en.json +62 -0
  208. package/dist/cdn/translations/transaction/en.json +4 -0
  209. package/dist/elements/internal/InternalCard/InternalCard.js +1 -1
  210. package/dist/elements/internal/InternalCard/InternalCard.js.map +1 -1
  211. package/dist/elements/internal/InternalDateControl/getMonthNames.js +2 -2
  212. package/dist/elements/internal/InternalDateControl/getMonthNames.js.map +1 -1
  213. package/dist/elements/internal/InternalForm/InternalForm.d.ts +2 -4
  214. package/dist/elements/internal/InternalForm/InternalForm.js +17 -9
  215. package/dist/elements/internal/InternalForm/InternalForm.js.map +1 -1
  216. package/dist/elements/internal/InternalForm/types.d.ts +9 -0
  217. package/dist/elements/internal/InternalForm/types.js.map +1 -1
  218. package/dist/elements/internal/InternalTextControl/InternalTextControl.d.ts +2 -1
  219. package/dist/elements/internal/InternalTextControl/InternalTextControl.js +39 -0
  220. package/dist/elements/internal/InternalTextControl/InternalTextControl.js.map +1 -1
  221. package/dist/elements/public/AdminSubscriptionForm/AdminSubscriptionForm.js +1 -2
  222. package/dist/elements/public/AdminSubscriptionForm/AdminSubscriptionForm.js.map +1 -1
  223. package/dist/elements/public/AdminSubscriptionForm/index.d.ts +1 -1
  224. package/dist/elements/public/AdminSubscriptionForm/index.js +1 -1
  225. package/dist/elements/public/AdminSubscriptionForm/index.js.map +1 -1
  226. package/dist/elements/public/AdminTransactionCard/AdminTransactionCard.d.ts +21 -0
  227. package/dist/elements/public/AdminTransactionCard/AdminTransactionCard.js +183 -0
  228. package/dist/elements/public/AdminTransactionCard/AdminTransactionCard.js.map +1 -0
  229. package/dist/elements/public/AdminTransactionCard/index.d.ts +6 -0
  230. package/dist/elements/public/AdminTransactionCard/index.js +8 -0
  231. package/dist/elements/public/AdminTransactionCard/index.js.map +1 -0
  232. package/dist/elements/public/AdminTransactionCard/types.d.ts +5 -0
  233. package/dist/elements/public/AdminTransactionCard/types.js +2 -0
  234. package/dist/elements/public/AdminTransactionCard/types.js.map +1 -0
  235. package/dist/elements/public/CartForm/internal/InternalCartFormTotalsControl/InternalCartFormTotalsControl.js +6 -6
  236. package/dist/elements/public/CartForm/internal/InternalCartFormTotalsControl/InternalCartFormTotalsControl.js.map +1 -1
  237. package/dist/elements/public/CartForm/types.d.ts +1 -1
  238. package/dist/elements/public/CartForm/types.js.map +1 -1
  239. package/dist/elements/public/CouponCodeForm/CouponCodeForm.d.ts +1 -0
  240. package/dist/elements/public/CouponCodeForm/CouponCodeForm.js +13 -1
  241. package/dist/elements/public/CouponCodeForm/CouponCodeForm.js.map +1 -1
  242. package/dist/elements/public/CouponCodeForm/index.d.ts +1 -1
  243. package/dist/elements/public/CouponCodeForm/index.js +1 -1
  244. package/dist/elements/public/CouponCodeForm/index.js.map +1 -1
  245. package/dist/elements/public/FilterAttributeCard/FilterAttributeCard.js +7 -3
  246. package/dist/elements/public/FilterAttributeCard/FilterAttributeCard.js.map +1 -1
  247. package/dist/elements/public/FormDialog/FormDialog.js +1 -0
  248. package/dist/elements/public/FormDialog/FormDialog.js.map +1 -1
  249. package/dist/elements/public/NucleonElement/NucleonElement.d.ts +2 -2
  250. package/dist/elements/public/NucleonElement/NucleonElement.js +19 -13
  251. package/dist/elements/public/NucleonElement/NucleonElement.js.map +1 -1
  252. package/dist/elements/public/PaymentsApi/api/types.d.ts +6 -0
  253. package/dist/elements/public/PaymentsApi/api/types.js.map +1 -1
  254. package/dist/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.js +31 -42
  255. package/dist/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.js.map +1 -1
  256. package/dist/elements/public/StoreForm/StoreForm.js +0 -2
  257. package/dist/elements/public/StoreForm/StoreForm.js.map +1 -1
  258. package/dist/elements/public/StoreTransactionFolderCard/StoreTransactionFolderCard.d.ts +27 -0
  259. package/dist/elements/public/StoreTransactionFolderCard/StoreTransactionFolderCard.js +134 -0
  260. package/dist/elements/public/StoreTransactionFolderCard/StoreTransactionFolderCard.js.map +1 -0
  261. package/dist/elements/public/StoreTransactionFolderCard/index.d.ts +5 -0
  262. package/dist/elements/public/StoreTransactionFolderCard/index.js +7 -0
  263. package/dist/elements/public/StoreTransactionFolderCard/index.js.map +1 -0
  264. package/dist/elements/public/StoreTransactionFolderCard/types.d.ts +3 -0
  265. package/dist/elements/public/StoreTransactionFolderCard/types.js +2 -0
  266. package/dist/elements/public/StoreTransactionFolderCard/types.js.map +1 -0
  267. package/dist/elements/public/StoreTransactionFolderForm/StoreTransactionFolderForm.d.ts +18 -0
  268. package/dist/elements/public/StoreTransactionFolderForm/StoreTransactionFolderForm.js +83 -0
  269. package/dist/elements/public/StoreTransactionFolderForm/StoreTransactionFolderForm.js.map +1 -0
  270. package/dist/elements/public/StoreTransactionFolderForm/index.d.ts +7 -0
  271. package/dist/elements/public/StoreTransactionFolderForm/index.js +9 -0
  272. package/dist/elements/public/StoreTransactionFolderForm/index.js.map +1 -0
  273. package/dist/elements/public/StoreTransactionFolderForm/internal/InternalStoreTransactionFolderFormColorControl/InternalStoreTransactionFolderFormColorControl.d.ts +8 -0
  274. package/dist/elements/public/StoreTransactionFolderForm/internal/InternalStoreTransactionFolderFormColorControl/InternalStoreTransactionFolderFormColorControl.js +74 -0
  275. package/dist/elements/public/StoreTransactionFolderForm/internal/InternalStoreTransactionFolderFormColorControl/InternalStoreTransactionFolderFormColorControl.js.map +1 -0
  276. package/dist/elements/public/StoreTransactionFolderForm/internal/InternalStoreTransactionFolderFormColorControl/index.d.ts +3 -0
  277. package/dist/elements/public/StoreTransactionFolderForm/internal/InternalStoreTransactionFolderFormColorControl/index.js +5 -0
  278. package/dist/elements/public/StoreTransactionFolderForm/internal/InternalStoreTransactionFolderFormColorControl/index.js.map +1 -0
  279. package/dist/elements/public/StoreTransactionFolderForm/types.d.ts +3 -0
  280. package/dist/elements/public/StoreTransactionFolderForm/types.js +2 -0
  281. package/dist/elements/public/StoreTransactionFolderForm/types.js.map +1 -0
  282. package/dist/elements/public/SubscriptionCard/SubscriptionCard.js +20 -7
  283. package/dist/elements/public/SubscriptionCard/SubscriptionCard.js.map +1 -1
  284. package/dist/elements/public/SwipeActions/SwipeActions.d.ts +0 -1
  285. package/dist/elements/public/SwipeActions/SwipeActions.js +6 -7
  286. package/dist/elements/public/SwipeActions/SwipeActions.js.map +1 -1
  287. package/dist/elements/public/TaxCard/TaxCard.js +2 -2
  288. package/dist/elements/public/TaxCard/TaxCard.js.map +1 -1
  289. package/dist/elements/public/TaxForm/TaxForm.js +0 -2
  290. package/dist/elements/public/TaxForm/TaxForm.js.map +1 -1
  291. package/dist/elements/public/TemplateConfigForm/internal/InternalTemplateConfigFormFilterValuesControl/InternalTemplateConfigFormFilterValuesControl.js +1 -3
  292. package/dist/elements/public/TemplateConfigForm/internal/InternalTemplateConfigFormFilterValuesControl/InternalTemplateConfigFormFilterValuesControl.js.map +1 -1
  293. package/dist/elements/public/Transaction/Transaction.d.ts +2 -3
  294. package/dist/elements/public/Transaction/Transaction.js +30 -6
  295. package/dist/elements/public/Transaction/Transaction.js.map +1 -1
  296. package/dist/elements/public/Transaction/internal/InternalTransactionActionsControl/InternalTransactionActionsControl.d.ts +5 -1
  297. package/dist/elements/public/Transaction/internal/InternalTransactionActionsControl/InternalTransactionActionsControl.js +87 -18
  298. package/dist/elements/public/Transaction/internal/InternalTransactionActionsControl/InternalTransactionActionsControl.js.map +1 -1
  299. package/dist/elements/public/Transaction/internal/InternalTransactionActionsControl/index.d.ts +1 -0
  300. package/dist/elements/public/Transaction/internal/InternalTransactionActionsControl/index.js +1 -0
  301. package/dist/elements/public/Transaction/internal/InternalTransactionActionsControl/index.js.map +1 -1
  302. package/dist/elements/public/Transaction/internal/InternalTransactionSummaryControl/InternalTransactionSummaryControl.js +6 -6
  303. package/dist/elements/public/Transaction/internal/InternalTransactionSummaryControl/InternalTransactionSummaryControl.js.map +1 -1
  304. package/dist/elements/public/Transaction/types.d.ts +1 -3
  305. package/dist/elements/public/Transaction/types.js.map +1 -1
  306. package/dist/elements/public/TransactionCard/TransactionCard.js +34 -6
  307. package/dist/elements/public/TransactionCard/TransactionCard.js.map +1 -1
  308. package/dist/elements/public/WebhookCard/types.d.ts +1 -3
  309. package/dist/elements/public/WebhookCard/types.js.map +1 -1
  310. package/dist/elements/public/index.d.ts +3 -0
  311. package/dist/elements/public/index.defined.d.ts +3 -0
  312. package/dist/elements/public/index.defined.js +3 -0
  313. package/dist/elements/public/index.defined.js.map +1 -1
  314. package/dist/elements/public/index.js +3 -0
  315. package/dist/elements/public/index.js.map +1 -1
  316. package/dist/mixins/themeable.js +106 -4
  317. package/dist/mixins/themeable.js.map +1 -1
  318. package/package.json +2 -2
  319. package/dist/cdn/shared-10da9bf0.js +0 -1
  320. package/dist/cdn/shared-1da47f50.js +0 -1
  321. package/dist/cdn/shared-4b24accb.js +0 -1
  322. package/dist/cdn/shared-5905fca4.js +0 -1
  323. package/dist/cdn/shared-69074dae.js +0 -1
  324. package/dist/cdn/shared-77829fbb.js +0 -1
  325. package/dist/cdn/shared-7a87cd33.js +0 -29
  326. package/dist/cdn/shared-a6e889a8.js +0 -1
  327. package/dist/cdn/shared-c66ca1f5.js +0 -1
  328. package/dist/cdn/shared-cb4ac1d2.js +0 -1
  329. package/dist/cdn/shared-f8e1143e.js +0 -1
  330. package/dist/cdn/shared-fc784ca0.js +0 -1
@@ -1,4 +1,4 @@
1
- import{C as e}from"./shared-c5c123c5.js";import"./shared-b5a0d106.js";import"./shared-278b8790.js";import{h as t,P as r}from"./shared-433eea12.js";import{F as o}from"./shared-5bcf861e.js";import{T as a,D as s}from"./shared-64e243c4.js";import{I as l}from"./shared-1e14a3fe.js";import"./shared-10da9bf0.js";import{_ as i}from"./shared-7fec42f2.js";import{i as h}from"./shared-53e42a77.js";import{h as d}from"./shared-ba5c42c7.js";const n=t`<dom-module id="lumo-checkbox-group" theme-for="vaadin-checkbox-group">
1
+ import{C as e}from"./shared-9e0b104a.js";import"./shared-6bf89411.js";import"./shared-e55c8dc4.js";import{h as t,P as r}from"./shared-5a469962.js";import{F as o}from"./shared-eb49be2e.js";import{T as a,D as s}from"./shared-66278c21.js";import{I as l}from"./shared-0b8768db.js";import"./shared-3d353eb8.js";import{_ as i}from"./shared-8f9014ff.js";import{i as h}from"./shared-53e42a77.js";import{h as d}from"./shared-ba5c42c7.js";const n=t`<dom-module id="lumo-checkbox-group" theme-for="vaadin-checkbox-group">
2
2
  <template>
3
3
  <style include="lumo-required-field">
4
4
  :host {
@@ -1,4 +1,4 @@
1
- import{P as e,B as t,d as i}from"./shared-5bcf861e.js";import{h as n}from"./shared-433eea12.js";
1
+ import{P as e,B as t,d as i}from"./shared-eb49be2e.js";import{h as n}from"./shared-5a469962.js";
2
2
  /**
3
3
  @license
4
4
  Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
@@ -1,4 +1,4 @@
1
- import{h as e}from"./shared-433eea12.js";import{N as t}from"./shared-1091aa45.js";
1
+ import{h as e}from"./shared-5a469962.js";import{N as t}from"./shared-be2ce0e6.js";
2
2
  /**
3
3
  @license
4
4
  Copyright (c) 2019 Vaadin Ltd.
@@ -1 +1 @@
1
- import{a as t,a5 as r,a6 as e,a7 as n,a8 as o,a9 as a,r as c,aa as u,ab as s,ac as f,ad as i,ae as b,af as j,ag as y,ah as v,ai as p,h as l,aj as d,ak as A,al as w,am as g}from"./shared-7fec42f2.js";import{b as h,a as m}from"./shared-d6a0954b.js";function O(t){return t}var x=Object.create,S=function(){function r(){}return function(e){if(!t(e))return{};if(x)return x(e);r.prototype=e;var n=new r;return r.prototype=void 0,n}}();function U(t,r){var e=-1,n=t.length;for(r||(r=Array(n));++e<n;)r[e]=t[e];return r}function I(t,r,e,n){var o=!e;e||(e={});for(var a=-1,c=r.length;++a<c;){var u=r[a],s=n?n(e[u],t[u],u,e,t):void 0;void 0===s&&(s=t[u]),o?h(e,u,s):m(e,u,s)}return e}var F=Object.prototype.hasOwnProperty;function B(e){if(!t(e))return function(t){var r=[];if(null!=t)for(var e in Object(t))r.push(e);return r}(e);var n=r(e),o=[];for(var a in e)("constructor"!=a||!n&&F.call(e,a))&&o.push(a);return o}function E(t){return e(t)?n(t,!0):B(t)}var M=o(Object.getPrototypeOf,Object);var D="object"==typeof exports&&exports&&!exports.nodeType&&exports,P=D&&"object"==typeof module&&module&&!module.nodeType&&module,k=P&&P.exports===D?c.Buffer:void 0,C=k?k.allocUnsafe:void 0;function L(t,r){if(r)return t.slice();var e=t.length,n=C?C(e):new t.constructor(e);return t.copy(n),n}var N=Object.getOwnPropertySymbols?function(t){for(var r=[];t;)f(r,u(t)),t=M(t);return r}:s;function R(t){return i(t,E,N)}var T=Object.prototype.hasOwnProperty;function V(t){var r=new t.constructor(t.byteLength);return new b(r).set(new b(t)),r}var G=/\w*$/;var W=j?j.prototype:void 0,$=W?W.valueOf:void 0;function q(t,r){var e=r?V(t.buffer):t.buffer;return new t.constructor(e,t.byteOffset,t.length)}var z="[object Boolean]",H="[object Date]",J="[object Map]",K="[object Number]",Q="[object RegExp]",X="[object Set]",Y="[object String]",Z="[object Symbol]",_="[object ArrayBuffer]",tt="[object DataView]",rt="[object Float32Array]",et="[object Float64Array]",nt="[object Int8Array]",ot="[object Int16Array]",at="[object Int32Array]",ct="[object Uint8Array]",ut="[object Uint8ClampedArray]",st="[object Uint16Array]",ft="[object Uint32Array]";function it(t,r,e){var n,o,a,c=t.constructor;switch(r){case _:return V(t);case z:case H:return new c(+t);case tt:return function(t,r){var e=r?V(t.buffer):t.buffer;return new t.constructor(e,t.byteOffset,t.byteLength)}(t,e);case rt:case et:case nt:case ot:case at:case ct:case ut:case st:case ft:return q(t,e);case J:return new c;case K:case Y:return new c(t);case Q:return(a=new(o=t).constructor(o.source,G.exec(o))).lastIndex=o.lastIndex,a;case X:return new c;case Z:return n=t,$?Object($.call(n)):{}}}function bt(t){return"function"!=typeof t.constructor||r(t)?{}:S(M(t))}var jt=p&&p.isMap,yt=jt?l(jt):function(t){return y(t)&&"[object Map]"==v(t)};var vt=p&&p.isSet,pt=vt?l(vt):function(t){return y(t)&&"[object Set]"==v(t)},lt=1,dt=2,At=4,wt="[object Arguments]",gt="[object Function]",ht="[object GeneratorFunction]",mt="[object Object]",Ot={};function xt(r,e,n,o,c,s){var f,i=e&lt,b=e&dt,j=e&At;if(n&&(f=c?n(r,o,c,s):n(r)),void 0!==f)return f;if(!t(r))return r;var y=d(r);if(y){if(f=function(t){var r=t.length,e=new t.constructor(r);return r&&"string"==typeof t[0]&&T.call(t,"index")&&(e.index=t.index,e.input=t.input),e}(r),!i)return U(r,f)}else{var p=v(r),l=p==gt||p==ht;if(A(r))return L(r,i);if(p==mt||p==wt||l&&!c){if(f=b||l?{}:bt(r),!i)return b?function(t,r){return I(t,N(t),r)}(r,function(t,r){return t&&I(r,E(r),t)}(f,r)):function(t,r){return I(t,u(t),r)}(r,function(t,r){return t&&I(r,a(r),t)}(f,r))}else{if(!Ot[p])return c?r:{};f=it(r,p,i)}}s||(s=new w);var h=s.get(r);if(h)return h;s.set(r,f),pt(r)?r.forEach((function(t){f.add(xt(t,e,n,t,r,s))})):yt(r)&&r.forEach((function(t,o){f.set(o,xt(t,e,n,o,r,s))}));var O=y?void 0:(j?b?R:g:b?E:a)(r);return function(t,r){for(var e=-1,n=null==t?0:t.length;++e<n&&!1!==r(t[e],e,t););}(O||r,(function(t,o){O&&(t=r[o=t]),m(f,o,xt(t,e,n,o,r,s))})),f}Ot[wt]=Ot["[object Array]"]=Ot["[object ArrayBuffer]"]=Ot["[object DataView]"]=Ot["[object Boolean]"]=Ot["[object Date]"]=Ot["[object Float32Array]"]=Ot["[object Float64Array]"]=Ot["[object Int8Array]"]=Ot["[object Int16Array]"]=Ot["[object Int32Array]"]=Ot["[object Map]"]=Ot["[object Number]"]=Ot[mt]=Ot["[object RegExp]"]=Ot["[object Set]"]=Ot["[object String]"]=Ot["[object Symbol]"]=Ot["[object Uint8Array]"]=Ot["[object Uint8ClampedArray]"]=Ot["[object Uint16Array]"]=Ot["[object Uint32Array]"]=!0,Ot["[object Error]"]=Ot[gt]=Ot["[object WeakMap]"]=!1;function St(t){return xt(t,5)}export{St as a,I as b,U as c,L as d,q as e,bt as f,M as g,O as i,E as k};
1
+ import{a as t,a5 as r,a6 as e,a7 as n,a8 as o,a9 as a,r as c,aa as u,ab as s,ac as f,ad as i,ae as b,af as j,ag as y,ah as v,ai as p,h as l,aj as d,ak as A,al as w,am as g}from"./shared-8f9014ff.js";import{b as h,a as m}from"./shared-9496e995.js";function O(t){return t}var x=Object.create,S=function(){function r(){}return function(e){if(!t(e))return{};if(x)return x(e);r.prototype=e;var n=new r;return r.prototype=void 0,n}}();function U(t,r){var e=-1,n=t.length;for(r||(r=Array(n));++e<n;)r[e]=t[e];return r}function I(t,r,e,n){var o=!e;e||(e={});for(var a=-1,c=r.length;++a<c;){var u=r[a],s=n?n(e[u],t[u],u,e,t):void 0;void 0===s&&(s=t[u]),o?h(e,u,s):m(e,u,s)}return e}var F=Object.prototype.hasOwnProperty;function B(e){if(!t(e))return function(t){var r=[];if(null!=t)for(var e in Object(t))r.push(e);return r}(e);var n=r(e),o=[];for(var a in e)("constructor"!=a||!n&&F.call(e,a))&&o.push(a);return o}function E(t){return e(t)?n(t,!0):B(t)}var M=o(Object.getPrototypeOf,Object);var D="object"==typeof exports&&exports&&!exports.nodeType&&exports,P=D&&"object"==typeof module&&module&&!module.nodeType&&module,k=P&&P.exports===D?c.Buffer:void 0,C=k?k.allocUnsafe:void 0;function L(t,r){if(r)return t.slice();var e=t.length,n=C?C(e):new t.constructor(e);return t.copy(n),n}var N=Object.getOwnPropertySymbols?function(t){for(var r=[];t;)f(r,u(t)),t=M(t);return r}:s;function R(t){return i(t,E,N)}var T=Object.prototype.hasOwnProperty;function V(t){var r=new t.constructor(t.byteLength);return new b(r).set(new b(t)),r}var G=/\w*$/;var W=j?j.prototype:void 0,$=W?W.valueOf:void 0;function q(t,r){var e=r?V(t.buffer):t.buffer;return new t.constructor(e,t.byteOffset,t.length)}var z="[object Boolean]",H="[object Date]",J="[object Map]",K="[object Number]",Q="[object RegExp]",X="[object Set]",Y="[object String]",Z="[object Symbol]",_="[object ArrayBuffer]",tt="[object DataView]",rt="[object Float32Array]",et="[object Float64Array]",nt="[object Int8Array]",ot="[object Int16Array]",at="[object Int32Array]",ct="[object Uint8Array]",ut="[object Uint8ClampedArray]",st="[object Uint16Array]",ft="[object Uint32Array]";function it(t,r,e){var n,o,a,c=t.constructor;switch(r){case _:return V(t);case z:case H:return new c(+t);case tt:return function(t,r){var e=r?V(t.buffer):t.buffer;return new t.constructor(e,t.byteOffset,t.byteLength)}(t,e);case rt:case et:case nt:case ot:case at:case ct:case ut:case st:case ft:return q(t,e);case J:return new c;case K:case Y:return new c(t);case Q:return(a=new(o=t).constructor(o.source,G.exec(o))).lastIndex=o.lastIndex,a;case X:return new c;case Z:return n=t,$?Object($.call(n)):{}}}function bt(t){return"function"!=typeof t.constructor||r(t)?{}:S(M(t))}var jt=p&&p.isMap,yt=jt?l(jt):function(t){return y(t)&&"[object Map]"==v(t)};var vt=p&&p.isSet,pt=vt?l(vt):function(t){return y(t)&&"[object Set]"==v(t)},lt=1,dt=2,At=4,wt="[object Arguments]",gt="[object Function]",ht="[object GeneratorFunction]",mt="[object Object]",Ot={};function xt(r,e,n,o,c,s){var f,i=e&lt,b=e&dt,j=e&At;if(n&&(f=c?n(r,o,c,s):n(r)),void 0!==f)return f;if(!t(r))return r;var y=d(r);if(y){if(f=function(t){var r=t.length,e=new t.constructor(r);return r&&"string"==typeof t[0]&&T.call(t,"index")&&(e.index=t.index,e.input=t.input),e}(r),!i)return U(r,f)}else{var p=v(r),l=p==gt||p==ht;if(A(r))return L(r,i);if(p==mt||p==wt||l&&!c){if(f=b||l?{}:bt(r),!i)return b?function(t,r){return I(t,N(t),r)}(r,function(t,r){return t&&I(r,E(r),t)}(f,r)):function(t,r){return I(t,u(t),r)}(r,function(t,r){return t&&I(r,a(r),t)}(f,r))}else{if(!Ot[p])return c?r:{};f=it(r,p,i)}}s||(s=new w);var h=s.get(r);if(h)return h;s.set(r,f),pt(r)?r.forEach((function(t){f.add(xt(t,e,n,t,r,s))})):yt(r)&&r.forEach((function(t,o){f.set(o,xt(t,e,n,o,r,s))}));var O=y?void 0:(j?b?R:g:b?E:a)(r);return function(t,r){for(var e=-1,n=null==t?0:t.length;++e<n&&!1!==r(t[e],e,t););}(O||r,(function(t,o){O&&(t=r[o=t]),m(f,o,xt(t,e,n,o,r,s))})),f}Ot[wt]=Ot["[object Array]"]=Ot["[object ArrayBuffer]"]=Ot["[object DataView]"]=Ot["[object Boolean]"]=Ot["[object Date]"]=Ot["[object Float32Array]"]=Ot["[object Float64Array]"]=Ot["[object Int8Array]"]=Ot["[object Int16Array]"]=Ot["[object Int32Array]"]=Ot["[object Map]"]=Ot["[object Number]"]=Ot[mt]=Ot["[object RegExp]"]=Ot["[object Set]"]=Ot["[object String]"]=Ot["[object Symbol]"]=Ot["[object Uint8Array]"]=Ot["[object Uint8ClampedArray]"]=Ot["[object Uint16Array]"]=Ot["[object Uint32Array]"]=!0,Ot["[object Error]"]=Ot[gt]=Ot["[object WeakMap]"]=!1;function St(t){return xt(t,5)}export{St as a,I as b,U as c,L as d,q as e,bt as f,M as g,O as i,E as k};
@@ -0,0 +1 @@
1
+ import"./foxy-spinner.js";import{I as e}from"./shared-6740e365.js";customElements.define("foxy-internal-card",e);
@@ -1 +1 @@
1
- import"./shared-a6b2bd14.js";import"./shared-f9d1baff.js";import"./shared-3c94ab84.js";import"./shared-fc784ca0.js";import{I as e}from"./shared-77829fbb.js";import{a as t}from"./shared-1e14a3fe.js";import"./shared-10da9bf0.js";import{i as s}from"./shared-53e42a77.js";import{h as o}from"./shared-ba5c42c7.js";import{c as r,_ as n,B as i}from"./shared-7fec42f2.js";import{S as a,a as l}from"./shared-7a87cd33.js";import{v as d}from"./shared-b738ee96.js";import{c}from"./shared-4e709717.js";let h,p=e=>e;customElements.define("foxy-internal-customer-form-legal-notice-control",class extends t{renderControl(){var e,t;const r=this.nucleon;return o(h||(h=p` <p class="leading-s text-xs text-secondary"> <foxy-i18n infer="" key="text"></foxy-i18n> <a class="font-medium text-body rounded hover-underline focus-outline-none focus-ring-2 focus-ring-primary-50" target="_blank" href="${0}" rel="noopener noreferrer"> <foxy-i18n infer="" key="link"></foxy-i18n> </a> </p> `),s(null===(t=null===(e=null==r?void 0:r.settings)||void 0===e?void 0:e.tos_checkbox_settings)||void 0===t?void 0:t.url))}});var u=r((function(e){!function(){const t=[{id:0,value:"Too weak",minDiversity:0,minLength:0},{id:1,value:"Weak",minDiversity:2,minLength:6},{id:2,value:"Medium",minDiversity:4,minLength:8},{id:3,value:"Strong",minDiversity:4,minLength:10}],s=(e,s=t,o="!\"#$%&'()*+,-./:;<=>?@[\\\\\\]^_`{|}~")=>{let r=e||"";s[0].minDiversity=0,s[0].minLength=0;const n=[{regex:"[a-z]",message:"lowercase"},{regex:"[A-Z]",message:"uppercase"},{regex:"[0-9]",message:"number"}];o&&n.push({regex:`[${o}]`,message:"symbol"});let i={};i.contains=n.filter((e=>new RegExp(`${e.regex}`).test(r))).map((e=>e.message)),i.length=r.length;let a=s.filter((e=>i.contains.length>=e.minDiversity)).filter((e=>i.length>=e.minLength)).sort(((e,t)=>t.id-e.id)).map((e=>({id:e.id,value:e.value})));return Object.assign(i,a[0]),i};e.exports={passwordStrength:s,defaultOptions:t}}()}));let m,f,_=e=>e;const g=a(l(e,"customer-form")),x=u.passwordStrength;class v extends g{constructor(){super(...arguments),this.passwordless=!1,this.settings=null,this.__passwordGeneratorOptions={checkStrength:e=>x(e).id>=2},this.__isAnonymousGetValue=()=>{var e;return!1===(null===(e=this.form)||void 0===e?void 0:e.is_anonymous)?"false":"true"},this.__isAnonymousSetValue=e=>{const t="true"===e;this.edit({is_anonymous:t}),t&&this.form.password&&this.edit({password:""}),t&&this.form.password_old&&this.edit({password_old:""}),t&&this.form.forgot_password&&this.edit({forgot_password:""})},this.__isAnonymousOptions=[{value:"true",label:"option_true"},{value:"false",label:"option_false"}],this.__refreshInterval=null}static get scopedElements(){return{"foxy-internal-customer-form-legal-notice-control":customElements.get("foxy-internal-customer-form-legal-notice-control"),"foxy-internal-radio-group-control":customElements.get("foxy-internal-radio-group-control"),"foxy-internal-timestamps-control":customElements.get("foxy-internal-timestamps-control"),"foxy-internal-password-control":customElements.get("foxy-internal-password-control"),"foxy-internal-submit-control":customElements.get("foxy-internal-submit-control"),"foxy-internal-delete-control":customElements.get("foxy-internal-delete-control"),"foxy-internal-text-control":customElements.get("foxy-internal-text-control"),"foxy-internal-undo-control":customElements.get("foxy-internal-undo-control"),"foxy-copy-to-clipboard":customElements.get("foxy-copy-to-clipboard"),"foxy-spinner":customElements.get("foxy-spinner"),"vcf-tooltip":customElements.get("vcf-tooltip"),"foxy-i18n":customElements.get("foxy-i18n"),"h-captcha":customElements.get("h-captcha"),"vaadin-button":customElements.get("vaadin-button")}}static get properties(){return n(n({},super.properties),{},{passwordless:{type:Boolean},settings:{type:Object}})}static get v8n(){return[({password:e,_links:t,is_anonymous:s=!0},o)=>!!o.passwordless||(!!(t||s||e)||"password:v8n_required"),({password_old:e,password:t,_links:s},o)=>{var r;return!s||(void 0===(null===(r=o.settings)||void 0===r?void 0:r.sign_up)||(!(t&&!e)||"password-old:v8n_required"))},({first_name:e})=>!e||e.length<=50||"first-name:v8n_too_long",({last_name:e})=>!e||e.length<=50||"last-name:v8n_too_long",({password:e})=>!e||x(e).id>=2||"password:v8n_too_weak",({password:e})=>!e||e.length<=50||"password:v8n_too_long",({tax_id:e})=>!e||e.length<=50||"tax-id:v8n_too_long",({email:e})=>e&&e.length>0||"email:v8n_required",({email:e})=>!e||e.length<=100||"email:v8n_too_long",({email:e})=>!e||d(e)||"email:v8n_invalid_email"]}get hiddenSelector(){const e=new Set(super.hiddenSelector.toString().split(" "));return this.settings?(e.add("forgot-password"),e.add("is-anonymous"),this.form.password||e.add("password-old"),"none"===this.settings.tos_checkbox_settings.usage&&e.add("legal-notice")):(!1!==this.form.is_anonymous&&(e.add("forgot-password"),e.add("password")),e.add("password-old"),e.add("legal-notice")),this.href&&(e.add("is-anonymous"),e.add("legal-notice")),new i(Array.from(e).join(" ").trim())}get headerTitleOptions(){var e,t;const s=this.data;return!s||(null===(e=s.first_name)||void 0===e?void 0:e.trim())||(null===(t=s.last_name)||void 0===t?void 0:t.trim())?super.headerTitleOptions:n(n({},super.headerTitleOptions),{},{context:"no_name"})}get headerSubtitleKey(){var e;return(null===(e=this.data)||void 0===e?void 0:e.is_anonymous)?"subtitle_anonymous":"subtitle_registered"}get headerSubtitleOptions(){return n(n({},super.headerSubtitleOptions),{},{id:this.headerCopyIdValue})}disconnectedCallback(){super.disconnectedCallback();const e=this.__refreshInterval;e&&clearInterval(e)}connectedCallback(){super.connectedCallback();const e=setInterval((()=>this.requestUpdate()),6e4);this.__refreshInterval=e}renderBody(){var e,t,s,r;const n=this.hiddenSelector.matches("first-name",!0),i=this.hiddenSelector.matches("last-name",!0);return o(m||(m=_` ${0} <div class="${0}"> <foxy-internal-text-control infer="first-name"></foxy-internal-text-control> <foxy-internal-text-control infer="last-name"></foxy-internal-text-control> </div> <foxy-internal-text-control helper-text="${0}" infer="email"> </foxy-internal-text-control> <foxy-internal-radio-group-control infer="is-anonymous" .getValue="${0}" .setValue="${0}" .options="${0}"> </foxy-internal-radio-group-control> <foxy-internal-password-control placeholder="${0}" helper-text="${0}" infer="password" show-generator .generatorOptions="${0}"> </foxy-internal-password-control> <foxy-internal-password-control infer="password-old"></foxy-internal-password-control> <foxy-internal-password-control helper-text="${0}" infer="forgot-password" show-generator> </foxy-internal-password-control> <foxy-internal-text-control infer="tax-id"></foxy-internal-text-control> <foxy-internal-customer-form-legal-notice-control infer="legal-notice"> </foxy-internal-customer-form-legal-notice-control> ${0} ${0} `),this.renderHeader(),c({"grid-cols-2":!n&&!i,hidden:n&&i,"gap-m":!0,grid:!n||!i}),this.__emailHelperText,this.__isAnonymousGetValue,this.__isAnonymousSetValue,this.__isAnonymousOptions,this.__passwordPlaceholder,this.__passwordHelperText,this.__passwordGeneratorOptions,this.__forgotPasswordHelperText,!this.data&&(null===(t=null===(e=this.settings)||void 0===e?void 0:e.sign_up)||void 0===t?void 0:t.enabled)&&"hcaptcha"===(null===(r=null===(s=this.settings)||void 0===s?void 0:s.sign_up)||void 0===r?void 0:r.verification.type)?o(f||(f=_` <h-captcha site-key="${0}" class="hidden" size="invisible" hl="${0}" @verified="${0}"> </h-captcha> `),this.settings.sign_up.verification.site_key,this.lang,(({token:e})=>{this.edit({verification:{type:"hcaptcha",token:e}}),super.submit()})):"",super.renderBody())}submit(){var e,t,s,o,r;"hcaptcha"!==(null===(s=null===(t=null===(e=this.settings)||void 0===e?void 0:e.sign_up)||void 0===t?void 0:t.verification)||void 0===s?void 0:s.type)||this.data?super.submit():(null===(o=this.__hcaptcha)||void 0===o||o.reset(),null===(r=this.__hcaptcha)||void 0===r||r.execute())}async _sendPatch(e){const t=await super._sendPatch(e);if(e.password){const e={key:"password_change_success",options:{email:t.email}};this.status=e}return t}async _sendGet(){return this.status=null,await super._sendGet()}async _fetch(...e){try{return await super._fetch(...e)}catch(e){let t;try{t=(await e.json())._embedded["fx:errors"][0].message}catch(t){throw e}throw"Conflict"===t||t.startsWith("This email address is already in use")?["error:email_already_used"]:t.startsWith("Customer registration is disabled")?["error:registration_disabled"]:t.startsWith("Client verification failed")?["error:verification_failed"]:t.startsWith("Provided password is incorrect")?["error:old_password_incorrect"]:e}}get __forgotPasswordHelperText(){var e,t;const s=null===(e=this.data)||void 0===e?void 0:e.forgot_password_timestamp,o="forgot-password.helper_text";if((null===(t=this.data)||void 0===t?void 0:t.forgot_password)&&s){const e=new Date(new Date(s).getTime()+18e5),t=Math.floor((e.getTime()-Date.now())/1e3/60);return t<=0?this.t(`${o}_expired_on`,{expiresOn:e}):this.t(`${o}_expires_in`,{expiresInMin:`${t}minutes`})}return this.t(o)}get __passwordPlaceholder(){return this.data?this.t("password.placeholder_new"):this.t("password.placeholder")}get __passwordHelperText(){return this.data?this.t("password.helper_text_new"):this.t("password.helper_text")}get __emailHelperText(){var e;return(null===(e=this.data)||void 0===e?void 0:e.last_login_date)?this.t("email.helper_text_last_login_date",{date:this.data.last_login_date}):this.t("email.helper_text")}get __hcaptcha(){return this.renderRoot.querySelector("h-captcha")}}customElements.define("foxy-customer-form",v);export{v as C,u};
1
+ import"./shared-a6b2bd14.js";import"./shared-15a75e70.js";import"./shared-4158f91e.js";import"./shared-5c8931a0.js";import{I as e}from"./shared-fc155659.js";import{a as t}from"./shared-0b8768db.js";import"./shared-3d353eb8.js";import{i as s}from"./shared-53e42a77.js";import{h as o}from"./shared-ba5c42c7.js";import{c as r,_ as n,B as i}from"./shared-8f9014ff.js";import{S as a,a as l}from"./shared-47f3f5f5.js";import{v as d}from"./shared-b738ee96.js";import{c}from"./shared-4e709717.js";let h,p=e=>e;customElements.define("foxy-internal-customer-form-legal-notice-control",class extends t{renderControl(){var e,t;const r=this.nucleon;return o(h||(h=p` <p class="leading-s text-xs text-secondary"> <foxy-i18n infer="" key="text"></foxy-i18n> <a class="font-medium text-body rounded hover-underline focus-outline-none focus-ring-2 focus-ring-primary-50" target="_blank" href="${0}" rel="noopener noreferrer"> <foxy-i18n infer="" key="link"></foxy-i18n> </a> </p> `),s(null===(t=null===(e=null==r?void 0:r.settings)||void 0===e?void 0:e.tos_checkbox_settings)||void 0===t?void 0:t.url))}});var u=r((function(e){!function(){const t=[{id:0,value:"Too weak",minDiversity:0,minLength:0},{id:1,value:"Weak",minDiversity:2,minLength:6},{id:2,value:"Medium",minDiversity:4,minLength:8},{id:3,value:"Strong",minDiversity:4,minLength:10}],s=(e,s=t,o="!\"#$%&'()*+,-./:;<=>?@[\\\\\\]^_`{|}~")=>{let r=e||"";s[0].minDiversity=0,s[0].minLength=0;const n=[{regex:"[a-z]",message:"lowercase"},{regex:"[A-Z]",message:"uppercase"},{regex:"[0-9]",message:"number"}];o&&n.push({regex:`[${o}]`,message:"symbol"});let i={};i.contains=n.filter((e=>new RegExp(`${e.regex}`).test(r))).map((e=>e.message)),i.length=r.length;let a=s.filter((e=>i.contains.length>=e.minDiversity)).filter((e=>i.length>=e.minLength)).sort(((e,t)=>t.id-e.id)).map((e=>({id:e.id,value:e.value})));return Object.assign(i,a[0]),i};e.exports={passwordStrength:s,defaultOptions:t}}()}));let m,f,_=e=>e;const g=a(l(e,"customer-form")),x=u.passwordStrength;class v extends g{constructor(){super(...arguments),this.passwordless=!1,this.settings=null,this.__passwordGeneratorOptions={checkStrength:e=>x(e).id>=2},this.__isAnonymousGetValue=()=>{var e;return!1===(null===(e=this.form)||void 0===e?void 0:e.is_anonymous)?"false":"true"},this.__isAnonymousSetValue=e=>{const t="true"===e;this.edit({is_anonymous:t}),t&&this.form.password&&this.edit({password:""}),t&&this.form.password_old&&this.edit({password_old:""}),t&&this.form.forgot_password&&this.edit({forgot_password:""})},this.__isAnonymousOptions=[{value:"true",label:"option_true"},{value:"false",label:"option_false"}],this.__refreshInterval=null}static get scopedElements(){return{"foxy-internal-customer-form-legal-notice-control":customElements.get("foxy-internal-customer-form-legal-notice-control"),"foxy-internal-radio-group-control":customElements.get("foxy-internal-radio-group-control"),"foxy-internal-timestamps-control":customElements.get("foxy-internal-timestamps-control"),"foxy-internal-password-control":customElements.get("foxy-internal-password-control"),"foxy-internal-submit-control":customElements.get("foxy-internal-submit-control"),"foxy-internal-delete-control":customElements.get("foxy-internal-delete-control"),"foxy-internal-text-control":customElements.get("foxy-internal-text-control"),"foxy-internal-undo-control":customElements.get("foxy-internal-undo-control"),"foxy-copy-to-clipboard":customElements.get("foxy-copy-to-clipboard"),"foxy-spinner":customElements.get("foxy-spinner"),"vcf-tooltip":customElements.get("vcf-tooltip"),"foxy-i18n":customElements.get("foxy-i18n"),"h-captcha":customElements.get("h-captcha"),"vaadin-button":customElements.get("vaadin-button")}}static get properties(){return n(n({},super.properties),{},{passwordless:{type:Boolean},settings:{type:Object}})}static get v8n(){return[({password:e,_links:t,is_anonymous:s=!0},o)=>!!o.passwordless||(!!(t||s||e)||"password:v8n_required"),({password_old:e,password:t,_links:s},o)=>{var r;return!s||(void 0===(null===(r=o.settings)||void 0===r?void 0:r.sign_up)||(!(t&&!e)||"password-old:v8n_required"))},({first_name:e})=>!e||e.length<=50||"first-name:v8n_too_long",({last_name:e})=>!e||e.length<=50||"last-name:v8n_too_long",({password:e})=>!e||x(e).id>=2||"password:v8n_too_weak",({password:e})=>!e||e.length<=50||"password:v8n_too_long",({tax_id:e})=>!e||e.length<=50||"tax-id:v8n_too_long",({email:e})=>e&&e.length>0||"email:v8n_required",({email:e})=>!e||e.length<=100||"email:v8n_too_long",({email:e})=>!e||d(e)||"email:v8n_invalid_email"]}get hiddenSelector(){const e=new Set(super.hiddenSelector.toString().split(" "));return this.settings?(e.add("forgot-password"),e.add("is-anonymous"),this.form.password||e.add("password-old"),"none"===this.settings.tos_checkbox_settings.usage&&e.add("legal-notice")):(!1!==this.form.is_anonymous&&(e.add("forgot-password"),e.add("password")),e.add("password-old"),e.add("legal-notice")),this.href&&(e.add("is-anonymous"),e.add("legal-notice")),new i(Array.from(e).join(" ").trim())}get headerTitleOptions(){var e,t;const s=this.data;return!s||(null===(e=s.first_name)||void 0===e?void 0:e.trim())||(null===(t=s.last_name)||void 0===t?void 0:t.trim())?super.headerTitleOptions:n(n({},super.headerTitleOptions),{},{context:"no_name"})}get headerSubtitleKey(){var e;return(null===(e=this.data)||void 0===e?void 0:e.is_anonymous)?"subtitle_anonymous":"subtitle_registered"}get headerSubtitleOptions(){return n(n({},super.headerSubtitleOptions),{},{id:this.headerCopyIdValue})}disconnectedCallback(){super.disconnectedCallback();const e=this.__refreshInterval;e&&clearInterval(e)}connectedCallback(){super.connectedCallback();const e=setInterval((()=>this.requestUpdate()),6e4);this.__refreshInterval=e}renderBody(){var e,t,s,r;const n=this.hiddenSelector.matches("first-name",!0),i=this.hiddenSelector.matches("last-name",!0);return o(m||(m=_` ${0} <div class="${0}"> <foxy-internal-text-control infer="first-name"></foxy-internal-text-control> <foxy-internal-text-control infer="last-name"></foxy-internal-text-control> </div> <foxy-internal-text-control helper-text="${0}" infer="email"> </foxy-internal-text-control> <foxy-internal-radio-group-control infer="is-anonymous" .getValue="${0}" .setValue="${0}" .options="${0}"> </foxy-internal-radio-group-control> <foxy-internal-password-control placeholder="${0}" helper-text="${0}" infer="password" show-generator .generatorOptions="${0}"> </foxy-internal-password-control> <foxy-internal-password-control infer="password-old"></foxy-internal-password-control> <foxy-internal-password-control helper-text="${0}" infer="forgot-password" show-generator> </foxy-internal-password-control> <foxy-internal-text-control infer="tax-id"></foxy-internal-text-control> <foxy-internal-customer-form-legal-notice-control infer="legal-notice"> </foxy-internal-customer-form-legal-notice-control> ${0} ${0} `),this.renderHeader(),c({"grid-cols-2":!n&&!i,hidden:n&&i,"gap-m":!0,grid:!n||!i}),this.__emailHelperText,this.__isAnonymousGetValue,this.__isAnonymousSetValue,this.__isAnonymousOptions,this.__passwordPlaceholder,this.__passwordHelperText,this.__passwordGeneratorOptions,this.__forgotPasswordHelperText,!this.data&&(null===(t=null===(e=this.settings)||void 0===e?void 0:e.sign_up)||void 0===t?void 0:t.enabled)&&"hcaptcha"===(null===(r=null===(s=this.settings)||void 0===s?void 0:s.sign_up)||void 0===r?void 0:r.verification.type)?o(f||(f=_` <h-captcha site-key="${0}" class="hidden" size="invisible" hl="${0}" @verified="${0}"> </h-captcha> `),this.settings.sign_up.verification.site_key,this.lang,(({token:e})=>{this.edit({verification:{type:"hcaptcha",token:e}}),super.submit()})):"",super.renderBody())}submit(){var e,t,s,o,r;"hcaptcha"!==(null===(s=null===(t=null===(e=this.settings)||void 0===e?void 0:e.sign_up)||void 0===t?void 0:t.verification)||void 0===s?void 0:s.type)||this.data?super.submit():(null===(o=this.__hcaptcha)||void 0===o||o.reset(),null===(r=this.__hcaptcha)||void 0===r||r.execute())}async _sendPatch(e){const t=await super._sendPatch(e);if(e.password){const e={key:"password_change_success",options:{email:t.email}};this.status=e}return t}async _sendGet(){return this.status=null,await super._sendGet()}async _fetch(...e){try{return await super._fetch(...e)}catch(e){let t;try{t=(await e.json())._embedded["fx:errors"][0].message}catch(t){throw e}throw"Conflict"===t||t.startsWith("This email address is already in use")?["error:email_already_used"]:t.startsWith("Customer registration is disabled")?["error:registration_disabled"]:t.startsWith("Client verification failed")?["error:verification_failed"]:t.startsWith("Provided password is incorrect")?["error:old_password_incorrect"]:e}}get __forgotPasswordHelperText(){var e,t;const s=null===(e=this.data)||void 0===e?void 0:e.forgot_password_timestamp,o="forgot-password.helper_text";if((null===(t=this.data)||void 0===t?void 0:t.forgot_password)&&s){const e=new Date(new Date(s).getTime()+18e5),t=Math.floor((e.getTime()-Date.now())/1e3/60);return t<=0?this.t(`${o}_expired_on`,{expiresOn:e}):this.t(`${o}_expires_in`,{expiresInMin:`${t}minutes`})}return this.t(o)}get __passwordPlaceholder(){return this.data?this.t("password.placeholder_new"):this.t("password.placeholder")}get __passwordHelperText(){return this.data?this.t("password.helper_text_new"):this.t("password.helper_text")}get __emailHelperText(){var e;return(null===(e=this.data)||void 0===e?void 0:e.last_login_date)?this.t("email.helper_text_last_login_date",{date:this.data.last_login_date}):this.t("email.helper_text")}get __hcaptcha(){return this.renderRoot.querySelector("h-captcha")}}customElements.define("foxy-customer-form",v);export{v as C,u};
@@ -1 +1 @@
1
- import"./shared-b5a0d106.js";const n=document.createElement("template");n.innerHTML='<dom-module id="lumo-required-field">\n <template>\n <style>\n [part="label"] {\n align-self: flex-start;\n color: var(--lumo-secondary-text-color);\n font-weight: 500;\n font-size: var(--lumo-font-size-s);\n margin-left: calc(var(--lumo-border-radius-m) / 4);\n transition: color 0.2s;\n line-height: 1;\n padding-bottom: 0.5em;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n position: relative;\n max-width: 100%;\n box-sizing: border-box;\n }\n\n :host([has-label])::before {\n margin-top: calc(var(--lumo-font-size-s) * 1.5);\n }\n\n :host([has-label]) {\n padding-top: var(--lumo-space-m);\n }\n\n :host([required]) [part="label"] {\n padding-right: 1em;\n }\n\n [part="label"]::after {\n content: var(--lumo-required-field-indicator, "•");\n transition: opacity 0.2s;\n opacity: 0;\n color: var(--lumo-primary-text-color);\n position: absolute;\n right: 0;\n width: 1em;\n text-align: center;\n }\n\n :host([required]:not([has-value])) [part="label"]::after {\n opacity: 1;\n }\n\n :host([invalid]) [part="label"]::after {\n color: var(--lumo-error-text-color);\n }\n\n [part="error-message"] {\n margin-left: calc(var(--lumo-border-radius-m) / 4);\n font-size: var(--lumo-font-size-xs);\n line-height: var(--lumo-line-height-xs);\n color: var(--lumo-error-text-color);\n will-change: max-height;\n transition: 0.4s max-height;\n max-height: 5em;\n }\n\n /* Margin that doesn’t reserve space when there’s no error message */\n [part="error-message"]:not(:empty)::before,\n [part="error-message"]:not(:empty)::after {\n content: "";\n display: block;\n height: 0.4em;\n }\n\n :host(:not([invalid])) [part="error-message"] {\n max-height: 0;\n overflow: hidden;\n }\n\n /* RTL specific styles */\n\n :host([dir="rtl"]) [part="label"] {\n margin-left: 0;\n margin-right: calc(var(--lumo-border-radius-m) / 4);\n }\n\n :host([required][dir="rtl"]) [part="label"] {\n padding-left: 1em;\n padding-right: 0;\n }\n\n :host([dir="rtl"]) [part="label"]::after {\n right: auto;\n left: 0;\n }\n\n :host([dir="rtl"]) [part="error-message"] {\n margin-left: 0;\n margin-right: calc(var(--lumo-border-radius-m) / 4);\n }\n\n </style>\n </template>\n</dom-module>',document.head.appendChild(n.content);
1
+ import"./shared-6bf89411.js";const n=document.createElement("template");n.innerHTML='<dom-module id="lumo-required-field">\n <template>\n <style>\n [part="label"] {\n align-self: flex-start;\n color: var(--lumo-secondary-text-color);\n font-weight: 500;\n font-size: var(--lumo-font-size-s);\n margin-left: calc(var(--lumo-border-radius-m) / 4);\n transition: color 0.2s;\n line-height: 1;\n padding-bottom: 0.5em;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n position: relative;\n max-width: 100%;\n box-sizing: border-box;\n }\n\n :host([has-label])::before {\n margin-top: calc(var(--lumo-font-size-s) * 1.5);\n }\n\n :host([has-label]) {\n padding-top: var(--lumo-space-m);\n }\n\n :host([required]) [part="label"] {\n padding-right: 1em;\n }\n\n [part="label"]::after {\n content: var(--lumo-required-field-indicator, "•");\n transition: opacity 0.2s;\n opacity: 0;\n color: var(--lumo-primary-text-color);\n position: absolute;\n right: 0;\n width: 1em;\n text-align: center;\n }\n\n :host([required]:not([has-value])) [part="label"]::after {\n opacity: 1;\n }\n\n :host([invalid]) [part="label"]::after {\n color: var(--lumo-error-text-color);\n }\n\n [part="error-message"] {\n margin-left: calc(var(--lumo-border-radius-m) / 4);\n font-size: var(--lumo-font-size-xs);\n line-height: var(--lumo-line-height-xs);\n color: var(--lumo-error-text-color);\n will-change: max-height;\n transition: 0.4s max-height;\n max-height: 5em;\n }\n\n /* Margin that doesn’t reserve space when there’s no error message */\n [part="error-message"]:not(:empty)::before,\n [part="error-message"]:not(:empty)::after {\n content: "";\n display: block;\n height: 0.4em;\n }\n\n :host(:not([invalid])) [part="error-message"] {\n max-height: 0;\n overflow: hidden;\n }\n\n /* RTL specific styles */\n\n :host([dir="rtl"]) [part="label"] {\n margin-left: 0;\n margin-right: calc(var(--lumo-border-radius-m) / 4);\n }\n\n :host([required][dir="rtl"]) [part="label"] {\n padding-left: 1em;\n padding-right: 0;\n }\n\n :host([dir="rtl"]) [part="label"]::after {\n right: auto;\n left: 0;\n }\n\n :host([dir="rtl"]) [part="error-message"] {\n margin-left: 0;\n margin-right: calc(var(--lumo-border-radius-m) / 4);\n }\n\n </style>\n </template>\n</dom-module>',document.head.appendChild(n.content);
@@ -1,4 +1,4 @@
1
- import{f as e,M as t,n as s,c as r,d as n,g as i,V as o,j as l,k as a,l as h,u as d,m as c,o as _,w as u,p,E as m,G as f,q as y,r as b,s as g,D as C,t as S,v,x as P,P as w,y as E,z as O,e as A,A as I}from"./shared-433eea12.js";import{q as x,c as T,k as N,h as D,t as M,v as k,f as R}from"./shared-7a87cd33.js";
1
+ import{f as e,M as t,n as s,c as r,d as n,g as i,V as o,j as l,k as a,l as h,u as d,m as c,o as _,w as u,p,E as m,G as f,q as y,r as b,s as g,D as C,t as S,v,x as P,P as w,y as E,z as O,e as A,A as I}from"./shared-5a469962.js";import{q as x,c as T,k as N,h as D,t as M,v as k,f as R}from"./shared-47f3f5f5.js";
2
2
  /**
3
3
  @license
4
4
  Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
@@ -1,4 +1,4 @@
1
- import"./shared-b5a0d106.js";import"./shared-809d503c.js";import{h as e,G as t,P as a,D as i,t as s,b as o,s as r}from"./shared-433eea12.js";import{C as n}from"./shared-5963a49e.js";import"./shared-a268320e.js";import"./shared-85ed835a.js";import{T as l}from"./shared-529a82a3.js";import"./shared-e7a2b31d.js";import{T as d,D as h,E as u}from"./shared-64e243c4.js";import{O as c,I as p,a as m}from"./shared-df7d368c.js";import{D as _,t as f,f as v,a as g}from"./shared-5bcf861e.js";import{a as y,b}from"./shared-e54135f0.js";const D=e`<dom-module id="lumo-date-picker-overlay" theme-for="vaadin-date-picker-overlay">
1
+ import"./shared-6bf89411.js";import"./shared-4194ffe7.js";import{h as e,G as t,P as a,D as i,t as s,b as o,s as r}from"./shared-5a469962.js";import{C as n}from"./shared-360196ad.js";import"./shared-27c16d99.js";import"./shared-0e25ac65.js";import{T as l}from"./shared-b3fe8c63.js";import"./shared-b01c3b62.js";import{T as h,D as d,E as u}from"./shared-66278c21.js";import{O as c,I as p,a as m}from"./shared-fb859ece.js";import{D as _,t as f,f as v,a as g}from"./shared-eb49be2e.js";import{a as y,b}from"./shared-32b2d003.js";const D=e`<dom-module id="lumo-date-picker-overlay" theme-for="vaadin-date-picker-overlay">
2
2
  <template>
3
3
  <style include="lumo-menu-overlay">
4
4
  [part="overlay"] {
@@ -450,7 +450,7 @@ const T=class{static _getISOWeekNumber(e){var t=e.getDay();0===t&&(t=7);var a=4-
450
450
  @license
451
451
  Copyright (c) 2017 Vaadin Ltd.
452
452
  This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
453
- */class I extends(d(t(a))){static get template(){return e`
453
+ */class I extends(h(t(a))){static get template(){return e`
454
454
  <style>
455
455
  :host {
456
456
  display: block;
@@ -575,7 +575,7 @@ class A extends a{static get template(){return e`
575
575
  Copyright (c) 2017 Vaadin Ltd.
576
576
  This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
577
577
  */
578
- class $ extends(d(h(t(a)))){static get template(){return e`
578
+ class $ extends(h(d(t(a)))){static get template(){return e`
579
579
  <style>
580
580
  :host {
581
581
  display: flex;
@@ -754,7 +754,7 @@ class $ extends(d(h(t(a)))){static get template(){return e`
754
754
  </div>
755
755
 
756
756
  <iron-media-query query="(min-width: 375px)" query-matches="{{_desktopMode}}"></iron-media-query>
757
- `}static get is(){return"vaadin-date-picker-overlay-content"}static get properties(){return{selectedDate:{type:Date,notify:!0},focusedDate:{type:Date,notify:!0,observer:"_focusedDateChanged"},_focusedMonthDate:Number,initialPosition:{type:Date,observer:"_initialPositionChanged"},_originDate:{value:new Date},_visibleMonthIndex:Number,_desktopMode:Boolean,_translateX:{observer:"_translateXChanged"},_yearScrollerWidth:{value:50},i18n:{type:Object},showWeekNumbers:{type:Boolean},_ignoreTaps:Boolean,_notTapping:Boolean,minDate:Date,maxDate:Date,_focused:Boolean,label:String}}get __isRTL(){return"rtl"===this.getAttribute("dir")}get __useSubMonthScrolling(){return this.$.monthScroller.clientHeight<this.$.monthScroller.itemHeight+this.$.monthScroller.bufferOffset}ready(){super.ready(),this.setAttribute("tabindex",0),this.addEventListener("keydown",this._onKeydown.bind(this)),o(this,"tap",this._stopPropagation),this.addEventListener("focus",this._onOverlayFocus.bind(this)),this.addEventListener("blur",this._onOverlayBlur.bind(this))}connectedCallback(){super.connectedCallback(),this._closeYearScroller(),this._toggleAnimateClass(!0),r(this.$.scrollers,"pan-y"),p.requestAvailability()}announceFocusedDate(){var e=this._currentlyFocusedDate(),t=[];T._dateEquals(e,new Date)&&t.push(this.i18n.today),t=t.concat([this.i18n.weekdays[e.getDay()],e.getDate(),this.i18n.monthNames[e.getMonth()],e.getFullYear()]),this.showWeekNumbers&&1===this.i18n.firstDayOfWeek&&(t.push(this.i18n.week),t.push(T._getISOWeekNumber(e))),this.dispatchEvent(new CustomEvent("iron-announce",{bubbles:!0,composed:!0,detail:{text:t.join(" ")}}))}focusCancel(){this.$.cancelButton.focus()}scrollToDate(e,t){const a=this.__useSubMonthScrolling?this._calculateWeekScrollOffset(e):0;this._scrollToPosition(this._differenceInMonths(e,this._originDate)+a,t),this.$.monthScroller.forceUpdate()}_focusedDateChanged(e){this.revealDate(e)}_isCurrentYear(e){return 0===e}_isSelectedYear(e,t){if(t)return t.getFullYear()===this._originDate.getFullYear()+e}revealDate(e,t=!0){if(!e)return;const a=this._differenceInMonths(e,this._originDate);if(this.__useSubMonthScrolling){const i=this._calculateWeekScrollOffset(e);return void this._scrollToPosition(a+i,t)}const i=this.$.monthScroller.position>a,s=Math.max(this.$.monthScroller.itemHeight,this.$.monthScroller.clientHeight-2*this.$.monthScroller.bufferOffset)/this.$.monthScroller.itemHeight,o=this.$.monthScroller.position+s-1<a;i?this._scrollToPosition(a,t):o&&this._scrollToPosition(a-s+1,t)}_calculateWeekScrollOffset(e){const t=new Date(0,0);t.setFullYear(e.getFullYear()),t.setMonth(e.getMonth()),t.setDate(1);let a=0;for(;t.getDate()<e.getDate();)t.setDate(t.getDate()+1),t.getDay()===this.i18n.firstDayOfWeek&&(a+=1);return a/6}_onOverlayFocus(){this._focused=!0}_onOverlayBlur(){this._focused=!1}_initialPositionChanged(e){this.scrollToDate(e)}_repositionYearScroller(){this._visibleMonthIndex=Math.floor(this.$.monthScroller.position),this.$.yearScroller.position=(this.$.monthScroller.position+this._originDate.getMonth())/12}_repositionMonthScroller(){this.$.monthScroller.position=12*this.$.yearScroller.position-this._originDate.getMonth(),this._visibleMonthIndex=Math.floor(this.$.monthScroller.position)}_onMonthScroll(){this._repositionYearScroller(),this._doIgnoreTaps()}_onYearScroll(){this._repositionMonthScroller(),this._doIgnoreTaps()}_onYearScrollTouchStart(){this._notTapping=!1,setTimeout((()=>this._notTapping=!0),300),this._repositionMonthScroller()}_onMonthScrollTouchStart(){this._repositionYearScroller()}_doIgnoreTaps(){this._ignoreTaps=!0,this._debouncer=i.debounce(this._debouncer,s.after(300),(()=>this._ignoreTaps=!1))}_formatDisplayed(e,t,a){return e?t(T._extractDateParts(e)):a}_onTodayTap(){var e=new Date;Math.abs(this.$.monthScroller.position-this._differenceInMonths(e,this._originDate))<.001?(this.selectedDate=e,this._close()):this._scrollToCurrentMonth()}_scrollToCurrentMonth(){this.focusedDate&&(this.focusedDate=new Date),this.scrollToDate(new Date,!0)}_showClear(e){return!!e}_onYearTap(e){if(!this._ignoreTaps&&!this._notTapping){var t=(e.detail.y-(this.$.yearScroller.getBoundingClientRect().top+this.$.yearScroller.clientHeight/2))/this.$.yearScroller.itemHeight;this._scrollToPosition(this.$.monthScroller.position+12*t,!0)}}_scrollToPosition(e,t){if(void 0===this._targetPosition){if(!t)return this.$.monthScroller.position=e,this._targetPosition=void 0,void this._repositionYearScroller();this._targetPosition=e;var a=t?300:0,i=0,s=this.$.monthScroller.position,o=e=>{var t,r,n,l=e-(i=i||e);if(l<a){var d=(t=l,r=s,n=this._targetPosition-s,(t/=a/2)<1?n/2*t*t+r:-n/2*(--t*(t-2)-1)+r);this.$.monthScroller.position=d,window.requestAnimationFrame(o)}else this.dispatchEvent(new CustomEvent("scroll-animation-finished",{bubbles:!0,composed:!0,detail:{position:this._targetPosition,oldPosition:s}})),this.$.monthScroller.position=this._targetPosition,this._targetPosition=void 0;setTimeout(this._repositionYearScroller.bind(this),1)};window.requestAnimationFrame(o)}else this._targetPosition=e}_limit(e,t){return Math.min(t.max,Math.max(t.min,e))}_handleTrack(e){if(!(Math.abs(e.detail.dx)<10||Math.abs(e.detail.ddy)>10)){Math.abs(e.detail.ddx)>this._yearScrollerWidth/3&&this._toggleAnimateClass(!0);var t=this._translateX+e.detail.ddx;this._translateX=this._limit(t,{min:0,max:this._yearScrollerWidth})}}_track(e){if(!this._desktopMode)switch(e.detail.state){case"start":this._toggleAnimateClass(!1);break;case"track":this._handleTrack(e);break;case"end":this._toggleAnimateClass(!0),this._translateX>=this._yearScrollerWidth/2?this._closeYearScroller():this._openYearScroller()}}_toggleAnimateClass(e){e?this.classList.add("animate"):this.classList.remove("animate")}_toggleYearScroller(){this._isYearScrollerVisible()?this._closeYearScroller():this._openYearScroller()}_openYearScroller(){this._translateX=0,this.setAttribute("years-visible","")}_closeYearScroller(){this.removeAttribute("years-visible"),this._translateX=this._yearScrollerWidth}_isYearScrollerVisible(){return this._translateX<this._yearScrollerWidth/2}_translateXChanged(e){this._desktopMode||(this.$.monthScroller.style.transform="translateX("+(e-this._yearScrollerWidth)+"px)",this.$.yearScroller.style.transform="translateX("+e+"px)")}_yearAfterXYears(e){var t=new Date(this._originDate);return t.setFullYear(parseInt(e)+this._originDate.getFullYear()),t.getFullYear()}_yearAfterXMonths(e){return this._dateAfterXMonths(e).getFullYear()}_dateAfterXMonths(e){var t=new Date(this._originDate);return t.setDate(1),t.setMonth(parseInt(e)+this._originDate.getMonth()),t}_differenceInMonths(e,t){return 12*(e.getFullYear()-t.getFullYear())-t.getMonth()+e.getMonth()}_differenceInYears(e,t){return this._differenceInMonths(e,t)/12}_clear(){this.selectedDate=""}_close(){const e=this.getRootNode().host,t=e?e.getRootNode().host:null;t&&(t.opened=!1),this.dispatchEvent(new CustomEvent("close",{bubbles:!0,composed:!0}))}_cancel(){this.focusedDate=this.selectedDate,this._close()}_preventDefault(e){e.preventDefault()}_eventKey(e){for(var t=["down","up","right","left","enter","space","home","end","pageup","pagedown","tab","esc"],a=0;a<t.length;a++){var i=t[a];if(m.keyboardEventMatchesKeys(e,i))return i}}_onKeydown(e){var t=this._currentlyFocusedDate();const a=e.composedPath().indexOf(this.$.todayButton)>=0,i=e.composedPath().indexOf(this.$.cancelButton)>=0,s=!a&&!i;var o=this._eventKey(e);if("tab"===o){e.stopPropagation();const t=this.hasAttribute("fullscreen"),o=e.shiftKey;t?e.preventDefault():o&&s||!o&&i?(e.preventDefault(),this.dispatchEvent(new CustomEvent("focus-input",{bubbles:!0,composed:!0}))):o&&a?(this._focused=!0,setTimeout((()=>this.revealDate(this.focusedDate)),1)):this._focused=!1}else if(o)switch(e.preventDefault(),e.stopPropagation(),o){case"down":this._moveFocusByDays(7),this.focus();break;case"up":this._moveFocusByDays(-7),this.focus();break;case"right":s&&this._moveFocusByDays(this.__isRTL?-1:1);break;case"left":s&&this._moveFocusByDays(this.__isRTL?1:-1);break;case"enter":s||i?this._close():a&&this._onTodayTap();break;case"space":if(i)this._close();else if(a)this._onTodayTap();else{var r=this.focusedDate;T._dateEquals(r,this.selectedDate)?(this.selectedDate="",this.focusedDate=r):this.selectedDate=r}break;case"home":this._moveFocusInsideMonth(t,"minDate");break;case"end":this._moveFocusInsideMonth(t,"maxDate");break;case"pagedown":this._moveFocusByMonths(e.shiftKey?12:1);break;case"pageup":this._moveFocusByMonths(e.shiftKey?-12:-1);break;case"esc":this._cancel()}}_currentlyFocusedDate(){return this.focusedDate||this.selectedDate||this.initialPosition||new Date}_focusDate(e){this.focusedDate=e,this._focusedMonthDate=e.getDate()}_focusClosestDate(e){this._focusDate(T._getClosestDate(e,[this.minDate,this.maxDate]))}_moveFocusByDays(e){var t=this._currentlyFocusedDate(),a=new Date(0,0);a.setFullYear(t.getFullYear()),a.setMonth(t.getMonth()),a.setDate(t.getDate()+e),this._dateAllowed(a,this.minDate,this.maxDate)?this._focusDate(a):this._dateAllowed(t,this.minDate,this.maxDate)?e>0?this._focusDate(this.maxDate):this._focusDate(this.minDate):this._focusClosestDate(t)}_moveFocusByMonths(e){var t=this._currentlyFocusedDate(),a=new Date(0,0);a.setFullYear(t.getFullYear()),a.setMonth(t.getMonth()+e);var i=a.getMonth();a.setDate(this._focusedMonthDate||(this._focusedMonthDate=t.getDate())),a.getMonth()!==i&&a.setDate(0),this._dateAllowed(a,this.minDate,this.maxDate)?this.focusedDate=a:this._dateAllowed(t,this.minDate,this.maxDate)?e>0?this._focusDate(this.maxDate):this._focusDate(this.minDate):this._focusClosestDate(t)}_moveFocusInsideMonth(e,t){var a=new Date(0,0);a.setFullYear(e.getFullYear()),"minDate"===t?(a.setMonth(e.getMonth()),a.setDate(1)):(a.setMonth(e.getMonth()+1),a.setDate(0)),this._dateAllowed(a,this.minDate,this.maxDate)?this._focusDate(a):this._dateAllowed(e,this.minDate,this.maxDate)?this._focusDate(this[t]):this._focusClosestDate(e)}_dateAllowed(e,t,a){return(!t||e>=t)&&(!a||e<=a)}_isTodayAllowed(e,t){var a=new Date,i=new Date(0,0);return i.setFullYear(a.getFullYear()),i.setMonth(a.getMonth()),i.setDate(a.getDate()),this._dateAllowed(i,e,t)}_stopPropagation(e){e.stopPropagation()}}customElements.define($.is,$);
757
+ `}static get is(){return"vaadin-date-picker-overlay-content"}static get properties(){return{selectedDate:{type:Date,notify:!0},focusedDate:{type:Date,notify:!0,observer:"_focusedDateChanged"},_focusedMonthDate:Number,initialPosition:{type:Date,observer:"_initialPositionChanged"},_originDate:{value:new Date},_visibleMonthIndex:Number,_desktopMode:Boolean,_translateX:{observer:"_translateXChanged"},_yearScrollerWidth:{value:50},i18n:{type:Object},showWeekNumbers:{type:Boolean},_ignoreTaps:Boolean,_notTapping:Boolean,minDate:Date,maxDate:Date,_focused:Boolean,label:String}}get __isRTL(){return"rtl"===this.getAttribute("dir")}get __useSubMonthScrolling(){return this.$.monthScroller.clientHeight<this.$.monthScroller.itemHeight+this.$.monthScroller.bufferOffset}ready(){super.ready(),this.setAttribute("tabindex",0),this.addEventListener("keydown",this._onKeydown.bind(this)),o(this,"tap",this._stopPropagation),this.addEventListener("focus",this._onOverlayFocus.bind(this)),this.addEventListener("blur",this._onOverlayBlur.bind(this))}connectedCallback(){super.connectedCallback(),this._closeYearScroller(),this._toggleAnimateClass(!0),r(this.$.scrollers,"pan-y"),p.requestAvailability()}announceFocusedDate(){var e=this._currentlyFocusedDate(),t=[];T._dateEquals(e,new Date)&&t.push(this.i18n.today),t=t.concat([this.i18n.weekdays[e.getDay()],e.getDate(),this.i18n.monthNames[e.getMonth()],e.getFullYear()]),this.showWeekNumbers&&1===this.i18n.firstDayOfWeek&&(t.push(this.i18n.week),t.push(T._getISOWeekNumber(e))),this.dispatchEvent(new CustomEvent("iron-announce",{bubbles:!0,composed:!0,detail:{text:t.join(" ")}}))}focusCancel(){this.$.cancelButton.focus()}scrollToDate(e,t){const a=this.__useSubMonthScrolling?this._calculateWeekScrollOffset(e):0;this._scrollToPosition(this._differenceInMonths(e,this._originDate)+a,t),this.$.monthScroller.forceUpdate()}_focusedDateChanged(e){this.revealDate(e)}_isCurrentYear(e){return 0===e}_isSelectedYear(e,t){if(t)return t.getFullYear()===this._originDate.getFullYear()+e}revealDate(e,t=!0){if(!e)return;const a=this._differenceInMonths(e,this._originDate);if(this.__useSubMonthScrolling){const i=this._calculateWeekScrollOffset(e);return void this._scrollToPosition(a+i,t)}const i=this.$.monthScroller.position>a,s=Math.max(this.$.monthScroller.itemHeight,this.$.monthScroller.clientHeight-2*this.$.monthScroller.bufferOffset)/this.$.monthScroller.itemHeight,o=this.$.monthScroller.position+s-1<a;i?this._scrollToPosition(a,t):o&&this._scrollToPosition(a-s+1,t)}_calculateWeekScrollOffset(e){const t=new Date(0,0);t.setFullYear(e.getFullYear()),t.setMonth(e.getMonth()),t.setDate(1);let a=0;for(;t.getDate()<e.getDate();)t.setDate(t.getDate()+1),t.getDay()===this.i18n.firstDayOfWeek&&(a+=1);return a/6}_onOverlayFocus(){this._focused=!0}_onOverlayBlur(){this._focused=!1}_initialPositionChanged(e){this.scrollToDate(e)}_repositionYearScroller(){this._visibleMonthIndex=Math.floor(this.$.monthScroller.position),this.$.yearScroller.position=(this.$.monthScroller.position+this._originDate.getMonth())/12}_repositionMonthScroller(){this.$.monthScroller.position=12*this.$.yearScroller.position-this._originDate.getMonth(),this._visibleMonthIndex=Math.floor(this.$.monthScroller.position)}_onMonthScroll(){this._repositionYearScroller(),this._doIgnoreTaps()}_onYearScroll(){this._repositionMonthScroller(),this._doIgnoreTaps()}_onYearScrollTouchStart(){this._notTapping=!1,setTimeout((()=>this._notTapping=!0),300),this._repositionMonthScroller()}_onMonthScrollTouchStart(){this._repositionYearScroller()}_doIgnoreTaps(){this._ignoreTaps=!0,this._debouncer=i.debounce(this._debouncer,s.after(300),(()=>this._ignoreTaps=!1))}_formatDisplayed(e,t,a){return e?t(T._extractDateParts(e)):a}_onTodayTap(){var e=new Date;Math.abs(this.$.monthScroller.position-this._differenceInMonths(e,this._originDate))<.001?(this.selectedDate=e,this._close()):this._scrollToCurrentMonth()}_scrollToCurrentMonth(){this.focusedDate&&(this.focusedDate=new Date),this.scrollToDate(new Date,!0)}_showClear(e){return!!e}_onYearTap(e){if(!this._ignoreTaps&&!this._notTapping){var t=(e.detail.y-(this.$.yearScroller.getBoundingClientRect().top+this.$.yearScroller.clientHeight/2))/this.$.yearScroller.itemHeight;this._scrollToPosition(this.$.monthScroller.position+12*t,!0)}}_scrollToPosition(e,t){if(void 0===this._targetPosition){if(!t)return this.$.monthScroller.position=e,this._targetPosition=void 0,void this._repositionYearScroller();this._targetPosition=e;var a=t?300:0,i=0,s=this.$.monthScroller.position,o=e=>{var t,r,n,l=e-(i=i||e);if(l<a){var h=(t=l,r=s,n=this._targetPosition-s,(t/=a/2)<1?n/2*t*t+r:-n/2*(--t*(t-2)-1)+r);this.$.monthScroller.position=h,window.requestAnimationFrame(o)}else this.dispatchEvent(new CustomEvent("scroll-animation-finished",{bubbles:!0,composed:!0,detail:{position:this._targetPosition,oldPosition:s}})),this.$.monthScroller.position=this._targetPosition,this._targetPosition=void 0;setTimeout(this._repositionYearScroller.bind(this),1)};window.requestAnimationFrame(o)}else this._targetPosition=e}_limit(e,t){return Math.min(t.max,Math.max(t.min,e))}_handleTrack(e){if(!(Math.abs(e.detail.dx)<10||Math.abs(e.detail.ddy)>10)){Math.abs(e.detail.ddx)>this._yearScrollerWidth/3&&this._toggleAnimateClass(!0);var t=this._translateX+e.detail.ddx;this._translateX=this._limit(t,{min:0,max:this._yearScrollerWidth})}}_track(e){if(!this._desktopMode)switch(e.detail.state){case"start":this._toggleAnimateClass(!1);break;case"track":this._handleTrack(e);break;case"end":this._toggleAnimateClass(!0),this._translateX>=this._yearScrollerWidth/2?this._closeYearScroller():this._openYearScroller()}}_toggleAnimateClass(e){e?this.classList.add("animate"):this.classList.remove("animate")}_toggleYearScroller(){this._isYearScrollerVisible()?this._closeYearScroller():this._openYearScroller()}_openYearScroller(){this._translateX=0,this.setAttribute("years-visible","")}_closeYearScroller(){this.removeAttribute("years-visible"),this._translateX=this._yearScrollerWidth}_isYearScrollerVisible(){return this._translateX<this._yearScrollerWidth/2}_translateXChanged(e){this._desktopMode||(this.$.monthScroller.style.transform="translateX("+(e-this._yearScrollerWidth)+"px)",this.$.yearScroller.style.transform="translateX("+e+"px)")}_yearAfterXYears(e){var t=new Date(this._originDate);return t.setFullYear(parseInt(e)+this._originDate.getFullYear()),t.getFullYear()}_yearAfterXMonths(e){return this._dateAfterXMonths(e).getFullYear()}_dateAfterXMonths(e){var t=new Date(this._originDate);return t.setDate(1),t.setMonth(parseInt(e)+this._originDate.getMonth()),t}_differenceInMonths(e,t){return 12*(e.getFullYear()-t.getFullYear())-t.getMonth()+e.getMonth()}_differenceInYears(e,t){return this._differenceInMonths(e,t)/12}_clear(){this.selectedDate=""}_close(){const e=this.getRootNode().host,t=e?e.getRootNode().host:null;t&&(t.opened=!1),this.dispatchEvent(new CustomEvent("close",{bubbles:!0,composed:!0}))}_cancel(){this.focusedDate=this.selectedDate,this._close()}_preventDefault(e){e.preventDefault()}_eventKey(e){for(var t=["down","up","right","left","enter","space","home","end","pageup","pagedown","tab","esc"],a=0;a<t.length;a++){var i=t[a];if(m.keyboardEventMatchesKeys(e,i))return i}}_onKeydown(e){var t=this._currentlyFocusedDate();const a=e.composedPath().indexOf(this.$.todayButton)>=0,i=e.composedPath().indexOf(this.$.cancelButton)>=0,s=!a&&!i;var o=this._eventKey(e);if("tab"===o){e.stopPropagation();const t=this.hasAttribute("fullscreen"),o=e.shiftKey;t?e.preventDefault():o&&s||!o&&i?(e.preventDefault(),this.dispatchEvent(new CustomEvent("focus-input",{bubbles:!0,composed:!0}))):o&&a?(this._focused=!0,setTimeout((()=>this.revealDate(this.focusedDate)),1)):this._focused=!1}else if(o)switch(e.preventDefault(),e.stopPropagation(),o){case"down":this._moveFocusByDays(7),this.focus();break;case"up":this._moveFocusByDays(-7),this.focus();break;case"right":s&&this._moveFocusByDays(this.__isRTL?-1:1);break;case"left":s&&this._moveFocusByDays(this.__isRTL?1:-1);break;case"enter":s||i?this._close():a&&this._onTodayTap();break;case"space":if(i)this._close();else if(a)this._onTodayTap();else{var r=this.focusedDate;T._dateEquals(r,this.selectedDate)?(this.selectedDate="",this.focusedDate=r):this.selectedDate=r}break;case"home":this._moveFocusInsideMonth(t,"minDate");break;case"end":this._moveFocusInsideMonth(t,"maxDate");break;case"pagedown":this._moveFocusByMonths(e.shiftKey?12:1);break;case"pageup":this._moveFocusByMonths(e.shiftKey?-12:-1);break;case"esc":this._cancel()}}_currentlyFocusedDate(){return this.focusedDate||this.selectedDate||this.initialPosition||new Date}_focusDate(e){this.focusedDate=e,this._focusedMonthDate=e.getDate()}_focusClosestDate(e){this._focusDate(T._getClosestDate(e,[this.minDate,this.maxDate]))}_moveFocusByDays(e){var t=this._currentlyFocusedDate(),a=new Date(0,0);a.setFullYear(t.getFullYear()),a.setMonth(t.getMonth()),a.setDate(t.getDate()+e),this._dateAllowed(a,this.minDate,this.maxDate)?this._focusDate(a):this._dateAllowed(t,this.minDate,this.maxDate)?e>0?this._focusDate(this.maxDate):this._focusDate(this.minDate):this._focusClosestDate(t)}_moveFocusByMonths(e){var t=this._currentlyFocusedDate(),a=new Date(0,0);a.setFullYear(t.getFullYear()),a.setMonth(t.getMonth()+e);var i=a.getMonth();a.setDate(this._focusedMonthDate||(this._focusedMonthDate=t.getDate())),a.getMonth()!==i&&a.setDate(0),this._dateAllowed(a,this.minDate,this.maxDate)?this.focusedDate=a:this._dateAllowed(t,this.minDate,this.maxDate)?e>0?this._focusDate(this.maxDate):this._focusDate(this.minDate):this._focusClosestDate(t)}_moveFocusInsideMonth(e,t){var a=new Date(0,0);a.setFullYear(e.getFullYear()),"minDate"===t?(a.setMonth(e.getMonth()),a.setDate(1)):(a.setMonth(e.getMonth()+1),a.setDate(0)),this._dateAllowed(a,this.minDate,this.maxDate)?this._focusDate(a):this._dateAllowed(e,this.minDate,this.maxDate)?this._focusDate(this[t]):this._focusClosestDate(e)}_dateAllowed(e,t,a){return(!t||e>=t)&&(!a||e<=a)}_isTodayAllowed(e,t){var a=new Date,i=new Date(0,0);return i.setFullYear(a.getFullYear()),i.setMonth(a.getMonth()),i.setDate(a.getDate()),this._dateAllowed(i,e,t)}_stopPropagation(e){e.stopPropagation()}}customElements.define($.is,$);
758
758
  /**
759
759
  @license
760
760
  Copyright (c) 2017 Vaadin Ltd.
@@ -765,7 +765,7 @@ const F=e=>class extends(g([b],e)){static get properties(){return{_selectedDate:
765
765
  @license
766
766
  Copyright (c) 2017 Vaadin Ltd.
767
767
  This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
768
- */;class Y extends(u(n(d(F(t(a)))))){static get template(){return e`
768
+ */;class Y extends(u(n(h(F(t(a)))))){static get template(){return e`
769
769
  <style>
770
770
  :host {
771
771
  display: inline-block;
@@ -1,4 +1,4 @@
1
- import"./shared-b5a0d106.js";import"./shared-809d503c.js";import{h as e,P as t,D as i,t as s,a as o,p as n,i as r,e as a,y as l,z as h}from"./shared-433eea12.js";import"./shared-a268320e.js";import{T as d,D as c,E as u}from"./shared-64e243c4.js";import{a as _,I as m,b as p}from"./shared-e54135f0.js";import"./shared-85ed835a.js";import"./shared-529a82a3.js";import{C as v}from"./shared-5963a49e.js";import{t as f,m as g,F as y,P as b,f as I,d as x,O as w,D as S,a as C}from"./shared-5bcf861e.js";
1
+ import"./shared-6bf89411.js";import"./shared-4194ffe7.js";import{h as e,P as t,D as i,t as s,a as o,p as n,i as r,e as a,y as l,z as h}from"./shared-5a469962.js";import"./shared-27c16d99.js";import{T as d,D as c,E as u}from"./shared-66278c21.js";import{a as _,I as m,b as p}from"./shared-32b2d003.js";import"./shared-0e25ac65.js";import"./shared-b3fe8c63.js";import{C as v}from"./shared-360196ad.js";import{t as f,m as g,F as y,P as b,f as I,d as x,O as w,D as S,a as C}from"./shared-eb49be2e.js";
2
2
  /**
3
3
  @license
4
4
  Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
@@ -0,0 +1 @@
1
+ import"./shared-360196ad.js";import"./shared-3d353eb8.js";import{a as e}from"./shared-0b8768db.js";import{h as t}from"./shared-ba5c42c7.js";import{l as r,_ as i,B as s}from"./shared-8f9014ff.js";import"./shared-1c985317.js";import"./foxy-copy-to-clipboard.js";import"./foxy-spinner.js";import{g as n}from"./shared-bab2ea2c.js";import{C as o}from"./shared-41c9c53f.js";import{T as a}from"./shared-47f3f5f5.js";import{N as l}from"./shared-9b138652.js";import{c as d}from"./shared-4e709717.js";let c,f=e=>e;customElements.define("foxy-internal-timestamps-control",class extends e{renderControl(){return t(c||(c=f` <p class="font-lumo text-s leading-s text-secondary"> <foxy-i18n infer="" key="date_created"></foxy-i18n> <foxy-i18n .options="${0}" infer="" key="date"> </foxy-i18n> <span>&bull;<span> <foxy-i18n infer="" key="date_modified"></foxy-i18n> <foxy-i18n .options="${0}" infer="" key="date"> </foxy-i18n> </span></span></p> `),{value:r(this,"nucleon.data.date_created")},{value:r(this,"nucleon.data.date_modified")})}});let h,u=e=>e;customElements.define("foxy-internal-submit-control",class extends e{constructor(){super(...arguments),this.theme="primary"}static get properties(){return i(i({},super.properties),{},{theme:{type:String}})}renderControl(){return t(h||(h=u` <vaadin-button theme="${0}" ?disabled="${0}" @click="${0}"> <foxy-i18n infer="" key="caption"></foxy-i18n> </vaadin-button> `),this.theme,this.disabled,(()=>{var e;return null===(e=this.nucleon)||void 0===e?void 0:e.submit()}))}});let p,y=e=>e;customElements.define("foxy-internal-delete-control",class extends e{constructor(){super(...arguments),this.theme="error"}static get properties(){return i(i({},super.properties),{},{theme:{type:String}})}renderControl(){return t(p||(p=y` <foxy-internal-confirm-dialog message="delete_prompt" confirm="delete" cancel="cancel" header="delete" theme="primary error" infer="" id="confirm" @hide="${0}"> </foxy-internal-confirm-dialog> <vaadin-button data-testid="delete" theme="${0}" class="w-full" ?disabled="${0}" @click="${0}"> <foxy-i18n infer="" key="delete"></foxy-i18n> </vaadin-button> `),(e=>{var t;return!e.detail.cancelled&&(null===(t=this.nucleon)||void 0===t?void 0:t.delete())}),this.theme,this.disabled||this.readonly,(e=>{this.renderRoot.querySelector("#confirm").show(e.currentTarget)}))}});let m,x=e=>e;customElements.define("foxy-internal-undo-control",class extends e{constructor(){super(...arguments),this.theme="secondary"}static get properties(){return i(i({},super.properties),{},{theme:{type:String}})}renderControl(){return t(m||(m=x` <vaadin-button theme="${0}" ?disabled="${0}" @click="${0}"> <foxy-i18n infer="" key="caption"></foxy-i18n> </vaadin-button> `),this.theme,this.disabled,(()=>{var e;return null===(e=this.nucleon)||void 0===e?void 0:e.undo()}))}});let b,g,v,$,k,S,_,j,E,O,T,C,w,B,K=e=>e;const H=o(a(l));class I extends H{constructor(){super(...arguments),this.status=null}static get properties(){return i(i({},super.properties),{},{status:{type:Object}})}renderHeaderActions(e){return null}get headerTitleKey(){return"title"}get headerTitleOptions(){return i(i({},this.data),{},{context:this.data?"existing":"new",id:this.data?n(this.data._links.self.href):null})}get headerSubtitleKey(){return"subtitle"}get headerSubtitleOptions(){var e;return null!==(e=this.data)&&void 0!==e?e:{}}get headerSubtitleBadges(){return[]}get headerCopyIdValue(){var e;return this.data&&null!==(e=n(this.data._links.self.href))&&void 0!==e?e:""}get hiddenSelector(){const e=[super.hiddenSelector.toString()];return this.href&&e.unshift("create"),this.href||e.unshift("delete","timestamps","submit"),this.in({idle:{snapshot:"dirty"}})||e.unshift("undo","submit"),new s(e.join(" ").trim())}renderHeader(){if(this.hiddenSelector.matches("header",!0))return t(b||(b=K``));const e=this.data,r=e?this.renderHeaderActions(e):null;return t(g||(g=K` <div> ${0} <h2 class="grid gap-xs"> <span class="flex items-center gap-s leading-none text-xl font-medium break-all"> <foxy-i18n options="${0}" infer="header" key="${0}"> </foxy-i18n> ${0} </span> ${0} </h2> ${0} </div> `),this.renderTemplateOrSlot("header:before"),JSON.stringify(this.headerTitleOptions),this.headerTitleKey,e?t(v||(v=K` ${0} ${0} `),this.hiddenSelector.matches("header:copy-id",!0)?"":t($||($=K` <foxy-copy-to-clipboard infer="header copy-id" class="text-m" text="${0}"> </foxy-copy-to-clipboard> `),this.headerCopyIdValue),this.hiddenSelector.matches("header:copy-json",!0)?"":t(k||(k=K` <foxy-copy-to-clipboard infer="header copy-json" class="text-m" icon="icons:code" text="${0}"> </foxy-copy-to-clipboard> `),JSON.stringify(e,null,2))):"",e?t(S||(S=K` <div class="flex flex-wrap items-center gap-s leading-xs"> ${0} <foxy-i18n infer="header" class="text-secondary" key="${0}" .options="${0}"> </foxy-i18n> </div> ${0} `),this.headerSubtitleBadges.map((e=>{var r;return t(_||(_=K` <span data-testclass="badge" class="${0}"> ${0} ${0} </span> `),d({"inline-flex gap-xs items-center rounded-s px-xs":!0,[null!==(r=e.class)&&void 0!==r?r:"bg-contrast-5"]:!0}),e.icon,"text"in e?e.text:t(j||(j=K`<foxy-i18n infer="header badges" key="${0}"></foxy-i18n>`),e.key))})),this.headerSubtitleKey,this.headerSubtitleOptions,r?t(E||(E=K`<div class="flex gap-x-m">${0}</div>`),r):""):"",this.renderTemplateOrSlot("header:after"))}renderBody(){return t(O||(O=K` <foxy-internal-timestamps-control infer="timestamps"></foxy-internal-timestamps-control> <div class="flex gap-m" ?hidden="${0}"> <foxy-internal-delete-control infer="delete"></foxy-internal-delete-control> <div class="w-full"></div> <foxy-internal-undo-control infer="undo"> </foxy-internal-undo-control> <foxy-internal-submit-control infer="submit"> </foxy-internal-submit-control> <foxy-internal-submit-control infer="create" theme="primary success"> </foxy-internal-submit-control> </div> `),["delete","undo","submit","create"].every((e=>this.hiddenSelector.matches(e,!0))))}render(){const e=!(this.in("idle")||this.in({busy:"fetching"})&&this.data);return t(T||(T=K` <div aria-busy="${0}" aria-live="polite" class="relative"> <div class="${0}"> ${0} ${0} ${0} </div> <div data-testid="spinner" class="${0}"> <foxy-spinner layout="${0}" state="${0}" infer="spinner"> </foxy-spinner> ${0} </div> </div> `),this.in("busy"),d({"space-y-m":!0,"transition-all filter":!0,"opacity-30 blur-sm pointer-events-none":e}),this.__generalErrors.map((e=>this.__renderGeneralError(e))),this.status?this.__renderStatus(this.status):"",this.renderBody(),d({"flex flex-col items-center justify-center gap-m":!0,"transition-opacity absolute inset-0":!0,"opacity-0 pointer-events-none":!e}),this.in("fail")?"vertical":"no-label",this.in("fail")?"error":"busy",this.href&&this.in("fail")?t(C||(C=K` <vaadin-button theme="small contrast" @click="${0}"> <foxy-i18n infer="spinner" key="refresh"></foxy-i18n> </vaadin-button> `),(()=>this.refresh())):"")}get __generalErrors(){const e=this.constructor.generalErrorPrefix;return this.errors.filter((t=>t.startsWith(e)))}__renderGeneralError(e){return t(w||(w=K` <foxy-i18n class="leading-xs text-body rounded bg-error-10 block" style="padding:calc(.625em + (var(--lumo-border-radius)/ 4) - 1px)" infer="error" key="${0}"> </foxy-i18n> `),e.replace("error:",""))}__renderStatus({key:e,options:r}){if(!this.hiddenSelector.matches("status",!0))return t(B||(B=K` <p data-testid="status" class="leading-xs text-body rounded bg-success-10 flex items-start gap-m" style="padding:calc(.625em + (var(--lumo-border-radius)/ 4) - 1px)"> <foxy-i18n class="flex-1" infer="status" key="${0}" .options="${0}"></foxy-i18n> <vaadin-button class="flex-shrink-0" theme="success tertiary-inline" @click="${0}"> <foxy-i18n class="flex-1" infer="status" key="close"></foxy-i18n> </vaadin-button> </p> `),e,r,(()=>this.status=null))}}I.generalErrorPrefix="error:",customElements.define("foxy-internal-form",I);export{I};
@@ -323,12 +323,10 @@
323
323
  "select": "Select...",
324
324
  "per_page": "Items per page:",
325
325
  "card": {
326
- "code": "Code",
327
- "customer": "Customer",
328
- "description": "Description",
329
326
  "price": "{{amount, price}}",
330
- "time": "{{value, date}}",
327
+ "time": "{{value, time}}",
331
328
  "test": "Test",
329
+ "folder_no_name": "New folder",
332
330
  "hidden_hint": "This transaction is archived",
333
331
  "status_capturing": "Capturing",
334
332
  "status_captured": "Captured",
@@ -337,7 +335,7 @@
337
335
  "status_pending": "Pending",
338
336
  "status_completed": "Completed",
339
337
  "status_problem": "Problem",
340
- "status_pending_fraud_review": "Pending_fraud_review",
338
+ "status_pending_fraud_review": "Pending fraud review",
341
339
  "status_rejected": "Rejected",
342
340
  "status_declined": "Declined",
343
341
  "status_refunding": "Refunding",
@@ -346,7 +344,9 @@
346
344
  "status_verified": "Verified",
347
345
  "summary": "{{first_item.name}}",
348
346
  "summary_plural": "{{first_item.name}} and {{count_minus_one}} more",
349
- "summary_payment_method_change": "Payment method change",
347
+ "summary_updateinfo": "Payment method change",
348
+ "summary_subscription_renewal": "Renewal: {{first_item.name}}",
349
+ "summary_subscription_renewal_plural": "Renewal: {{first_item.name}} and {{count_minus_one}} more",
350
350
  "summary_subscription_modification": "Subscription modification",
351
351
  "summary_subscription_cancellation": "Subscription cancellation",
352
352
  "source_MIT": "This transaction was initiated by the merchant",
@@ -0,0 +1,35 @@
1
+ {
2
+ "price": "{{amount, price}}",
3
+ "time": "{{value, time}}",
4
+ "test": "Test",
5
+ "folder_no_name": "New folder",
6
+ "hidden_hint": "This transaction is archived",
7
+ "status_capturing": "Capturing",
8
+ "status_captured": "Captured",
9
+ "status_approved": "Approved",
10
+ "status_authorized": "Authorized",
11
+ "status_pending": "Pending",
12
+ "status_completed": "Completed",
13
+ "status_problem": "Problem",
14
+ "status_pending_fraud_review": "Pending fraud review",
15
+ "status_rejected": "Rejected",
16
+ "status_declined": "Declined",
17
+ "status_refunding": "Refunding",
18
+ "status_refunded": "Refunded",
19
+ "status_voided": "Voided",
20
+ "status_verified": "Verified",
21
+ "summary": "{{first_item.name}}",
22
+ "summary_plural": "{{first_item.name}} and {{count_minus_one}} more",
23
+ "summary_updateinfo": "Payment method change",
24
+ "summary_subscription_renewal": "Renewal: {{first_item.name}}",
25
+ "summary_subscription_renewal_plural": "Renewal: {{first_item.name}} and {{count_minus_one}} more",
26
+ "summary_subscription_modification": "Subscription modification",
27
+ "summary_subscription_cancellation": "Subscription cancellation",
28
+ "source_MIT": "This transaction was initiated by the merchant",
29
+ "source_CIT": "This transaction was initiated by the customer",
30
+ "spinner": {
31
+ "loading_busy": "Loading",
32
+ "loading_empty": "No data",
33
+ "loading_error": "Unknown error"
34
+ }
35
+ }
@@ -40,12 +40,10 @@
40
40
  "select": "Select...",
41
41
  "per_page": "Items per page:",
42
42
  "card": {
43
- "code": "Code",
44
- "customer": "Customer",
45
- "description": "Description",
46
43
  "price": "{{amount, price}}",
47
- "time": "{{value, date}}",
44
+ "time": "{{value, time}}",
48
45
  "test": "Test",
46
+ "folder_no_name": "New folder",
49
47
  "hidden_hint": "This transaction is archived",
50
48
  "status_capturing": "Capturing",
51
49
  "status_captured": "Captured",
@@ -54,7 +52,7 @@
54
52
  "status_pending": "Pending",
55
53
  "status_completed": "Completed",
56
54
  "status_problem": "Problem",
57
- "status_pending_fraud_review": "Pending_fraud_review",
55
+ "status_pending_fraud_review": "Pending fraud review",
58
56
  "status_rejected": "Rejected",
59
57
  "status_declined": "Declined",
60
58
  "status_refunding": "Refunding",
@@ -63,7 +61,9 @@
63
61
  "status_verified": "Verified",
64
62
  "summary": "{{first_item.name}}",
65
63
  "summary_plural": "{{first_item.name}} and {{count_minus_one}} more",
66
- "summary_payment_method_change": "Payment method change",
64
+ "summary_updateinfo": "Payment method change",
65
+ "summary_subscription_renewal": "Renewal: {{first_item.name}}",
66
+ "summary_subscription_renewal_plural": "Renewal: {{first_item.name}} and {{count_minus_one}} more",
67
67
  "summary_subscription_modification": "Subscription modification",
68
68
  "summary_subscription_cancellation": "Subscription cancellation",
69
69
  "source_MIT": "This transaction was initiated by the merchant",
@@ -0,0 +1,8 @@
1
+ {
2
+ "no_name": "New folder",
3
+ "spinner": {
4
+ "loading_busy": "Loading",
5
+ "loading_empty": "No data",
6
+ "loading_error": "Unknown error"
7
+ }
8
+ }
@@ -0,0 +1,62 @@
1
+ {
2
+ "error": {
3
+ "folder_not_empty": "This folder is not empty. Please remove all transactions from this folder before deleting it."
4
+ },
5
+ "group-one": {
6
+ "label": "",
7
+ "helper_text": "",
8
+ "name": {
9
+ "label": "Name",
10
+ "helper_text": "",
11
+ "placeholder": "New folder"
12
+ },
13
+ "color": {
14
+ "label": "Color",
15
+ "color_red": "Red",
16
+ "color_red_pale": "Pale red",
17
+ "color_green": "Green",
18
+ "color_green_pale": "Pale green",
19
+ "color_blue": "Blue",
20
+ "color_blue_pale": "Pale blue",
21
+ "color_orange": "Orange",
22
+ "color_orange_pale": "Pale orange",
23
+ "color_violet": "Violet",
24
+ "color_violet_pale": "Pale violet",
25
+ "color_none": "None"
26
+ }
27
+ },
28
+ "group-two": {
29
+ "label": "",
30
+ "helper_text": "",
31
+ "is-default": {
32
+ "label": "Make default",
33
+ "helper_text": "All new transactions will appear in this folder by default. Only one folder can be the default.",
34
+ "checked": "Yes",
35
+ "unchecked": "No"
36
+ }
37
+ },
38
+ "timestamps": {
39
+ "date_created": "Created on",
40
+ "date_modified": "Last updated on",
41
+ "date": "{{value, date}}"
42
+ },
43
+ "spinner": {
44
+ "refresh": "Refresh",
45
+ "loading_busy": "Loading",
46
+ "loading_error": "Unknown error"
47
+ },
48
+ "delete": {
49
+ "delete": "Delete",
50
+ "cancel": "Cancel",
51
+ "delete_prompt": "Are you sure you'd like to remove this folder? You won't be able to bring it back."
52
+ },
53
+ "undo": {
54
+ "caption": "Undo"
55
+ },
56
+ "submit": {
57
+ "caption": "Save changes"
58
+ },
59
+ "create": {
60
+ "caption": "Create"
61
+ }
62
+ }
@@ -1775,6 +1775,10 @@
1775
1775
  "archive": {
1776
1776
  "caption_archive": "Archive",
1777
1777
  "caption_unarchive": "Unarchive"
1778
+ },
1779
+ "folder": {
1780
+ "caption": "Move to folder",
1781
+ "option_none": "None"
1778
1782
  }
1779
1783
  },
1780
1784
  "spinner": {
@@ -26,7 +26,7 @@ export class InternalCard extends ThemeableMixin(NucleonElement) {
26
26
  <div
27
27
  aria-busy=${this.in('busy')}
28
28
  aria-live="polite"
29
- class="relative leading-m text-body text-m font-lumo"
29
+ class="relative leading-s text-body text-m font-lumo"
30
30
  >
31
31
  <div
32
32
  class=${classMap({
@@ -1 +1 @@
1
- {"version":3,"file":"InternalCard.js","sourceRoot":"","sources":["../../../../src/elements/internal/InternalCard/InternalCard.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,cAAc,EAAE,qCAAkC;AAC3D,OAAO,EAAE,cAAc,EAAE,sDAAmD;AAC5E,OAAO,EAAE,QAAQ,EAAE,oCAAiC;AACpD,OAAO,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAEhC;;;;;GAKG;AACH,MAAM,OAAO,YAAiC,SAAQ,cAAc,CAAC,cAAc,CAAQ;IACzF;;;OAGG;IACH,UAAU;QACR,OAAO,IAAI,CAAA,EAAE,CAAC;IAChB,CAAC;IAED,MAAM;QACJ,MAAM,YAAY,GAAG,IAAI,CAAC,EAAE,CAAC,MAAM,CAAC;YAClC,CAAC,CAAC,OAAO;YACT,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,CAAC;gBAC/B,CAAC,CAAC,OAAO;gBACT,CAAC,CAAC,MAAM,CAAC;QAEX,OAAO,IAAI,CAAA;;oBAEK,IAAI,CAAC,EAAE,CAAC,MAAM,CAAC;;;;;kBAKjB,QAAQ,CAAC;YACf,qCAAqC,EAAE,IAAI;YAC3C,+BAA+B,EAAE,CAAC,IAAI,CAAC,WAAW;SACnD,CAAC;;YAEA,IAAI,CAAC,UAAU,EAAE;;;;kBAIX,QAAQ,CAAC;YACf,2DAA2D,EAAE,IAAI;YACjE,6BAA6B,EAAE,IAAI;YACnC,+BAA+B,EAAE,IAAI,CAAC,WAAW;SAClD,CAAC;;;qBAGS,YAAY,KAAK,MAAM,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,YAAY;oBACpD,YAAY;;;;;;KAM3B,CAAC;IACJ,CAAC;IAED,IAAI,WAAW;QACb,OAAO,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC;IACrB,CAAC;CACF","sourcesContent":["import type { HALJSONResource as Data } from '../../public/NucleonElement/types';\nimport type { TemplateResult } from 'lit-html';\n\nimport { ThemeableMixin } from '../../../mixins/themeable';\nimport { NucleonElement } from '../../public/NucleonElement/NucleonElement';\nimport { classMap } from '../../../utils/class-map';\nimport { html } from 'lit-html';\n\n/**\n * Internal base element for cards.\n *\n * @since 1.17.0\n * @element foxy-internal-card\n */\nexport class InternalCard<TData extends Data> extends ThemeableMixin(NucleonElement)<TData> {\n /**\n * Invoked together with `.render()` to obtain a template for card contents.\n * When extending `InternalCard`, prefer overriding this method to `.render()`.\n */\n renderBody(): TemplateResult {\n return html``;\n }\n\n render(): TemplateResult {\n const spinnerState = this.in('fail')\n ? 'error'\n : this.in({ idle: 'template' })\n ? 'empty'\n : 'busy';\n\n return html`\n <div\n aria-busy=${this.in('busy')}\n aria-live=\"polite\"\n class=\"relative leading-m text-body text-m font-lumo\"\n >\n <div\n class=${classMap({\n 'transition duration-500 ease-in-out': true,\n 'opacity-0 pointer-events-none': !this.isBodyReady,\n })}\n >\n ${this.renderBody()}\n </div>\n\n <div\n class=${classMap({\n 'transition duration-500 ease-in-out absolute inset-0 flex': true,\n 'items-center justify-center': true,\n 'opacity-0 pointer-events-none': this.isBodyReady,\n })}\n >\n <foxy-spinner\n layout=${spinnerState === 'busy' ? 'no-label' : 'horizontal'}\n state=${spinnerState}\n infer=\"spinner\"\n >\n </foxy-spinner>\n </div>\n </div>\n `;\n }\n\n get isBodyReady(): boolean {\n return !!this.data;\n }\n}\n"]}
1
+ {"version":3,"file":"InternalCard.js","sourceRoot":"","sources":["../../../../src/elements/internal/InternalCard/InternalCard.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,cAAc,EAAE,qCAAkC;AAC3D,OAAO,EAAE,cAAc,EAAE,sDAAmD;AAC5E,OAAO,EAAE,QAAQ,EAAE,oCAAiC;AACpD,OAAO,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAEhC;;;;;GAKG;AACH,MAAM,OAAO,YAAiC,SAAQ,cAAc,CAAC,cAAc,CAAQ;IACzF;;;OAGG;IACH,UAAU;QACR,OAAO,IAAI,CAAA,EAAE,CAAC;IAChB,CAAC;IAED,MAAM;QACJ,MAAM,YAAY,GAAG,IAAI,CAAC,EAAE,CAAC,MAAM,CAAC;YAClC,CAAC,CAAC,OAAO;YACT,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,CAAC;gBAC/B,CAAC,CAAC,OAAO;gBACT,CAAC,CAAC,MAAM,CAAC;QAEX,OAAO,IAAI,CAAA;;oBAEK,IAAI,CAAC,EAAE,CAAC,MAAM,CAAC;;;;;kBAKjB,QAAQ,CAAC;YACf,qCAAqC,EAAE,IAAI;YAC3C,+BAA+B,EAAE,CAAC,IAAI,CAAC,WAAW;SACnD,CAAC;;YAEA,IAAI,CAAC,UAAU,EAAE;;;;kBAIX,QAAQ,CAAC;YACf,2DAA2D,EAAE,IAAI;YACjE,6BAA6B,EAAE,IAAI;YACnC,+BAA+B,EAAE,IAAI,CAAC,WAAW;SAClD,CAAC;;;qBAGS,YAAY,KAAK,MAAM,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,YAAY;oBACpD,YAAY;;;;;;KAM3B,CAAC;IACJ,CAAC;IAED,IAAI,WAAW;QACb,OAAO,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC;IACrB,CAAC;CACF","sourcesContent":["import type { HALJSONResource as Data } from '../../public/NucleonElement/types';\nimport type { TemplateResult } from 'lit-html';\n\nimport { ThemeableMixin } from '../../../mixins/themeable';\nimport { NucleonElement } from '../../public/NucleonElement/NucleonElement';\nimport { classMap } from '../../../utils/class-map';\nimport { html } from 'lit-html';\n\n/**\n * Internal base element for cards.\n *\n * @since 1.17.0\n * @element foxy-internal-card\n */\nexport class InternalCard<TData extends Data> extends ThemeableMixin(NucleonElement)<TData> {\n /**\n * Invoked together with `.render()` to obtain a template for card contents.\n * When extending `InternalCard`, prefer overriding this method to `.render()`.\n */\n renderBody(): TemplateResult {\n return html``;\n }\n\n render(): TemplateResult {\n const spinnerState = this.in('fail')\n ? 'error'\n : this.in({ idle: 'template' })\n ? 'empty'\n : 'busy';\n\n return html`\n <div\n aria-busy=${this.in('busy')}\n aria-live=\"polite\"\n class=\"relative leading-s text-body text-m font-lumo\"\n >\n <div\n class=${classMap({\n 'transition duration-500 ease-in-out': true,\n 'opacity-0 pointer-events-none': !this.isBodyReady,\n })}\n >\n ${this.renderBody()}\n </div>\n\n <div\n class=${classMap({\n 'transition duration-500 ease-in-out absolute inset-0 flex': true,\n 'items-center justify-center': true,\n 'opacity-0 pointer-events-none': this.isBodyReady,\n })}\n >\n <foxy-spinner\n layout=${spinnerState === 'busy' ? 'no-label' : 'horizontal'}\n state=${spinnerState}\n infer=\"spinner\"\n >\n </foxy-spinner>\n </div>\n </div>\n `;\n }\n\n get isBodyReady(): boolean {\n return !!this.data;\n }\n}\n"]}
@@ -1,6 +1,6 @@
1
1
  export function getMonthNames(lang) {
2
- return new Array(12).fill(new Date()).map((date, i) => {
3
- date.setMonth(i);
2
+ return new Array(12).fill(null).map((_, i) => {
3
+ const date = new Date(2000, i, 1);
4
4
  return date.toLocaleDateString(lang, { month: 'long' });
5
5
  });
6
6
  }
@@ -1 +1 @@
1
- {"version":3,"file":"getMonthNames.js","sourceRoot":"","sources":["../../../../src/elements/internal/InternalDateControl/getMonthNames.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,aAAa,CAAC,IAAY;IACxC,OAAO,IAAI,KAAK,CAAC,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,IAAU,EAAE,CAAC,EAAE,EAAE;QAC1D,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC;QACjB,OAAO,IAAI,CAAC,kBAAkB,CAAC,IAAI,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,CAAC,CAAC;IAC1D,CAAC,CAAC,CAAC;AACL,CAAC","sourcesContent":["export function getMonthNames(lang: string): string[] {\n return new Array(12).fill(new Date()).map((date: Date, i) => {\n date.setMonth(i);\n return date.toLocaleDateString(lang, { month: 'long' });\n });\n}\n"]}
1
+ {"version":3,"file":"getMonthNames.js","sourceRoot":"","sources":["../../../../src/elements/internal/InternalDateControl/getMonthNames.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,aAAa,CAAC,IAAY;IACxC,OAAO,IAAI,KAAK,CAAC,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE;QAC3C,MAAM,IAAI,GAAG,IAAI,IAAI,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;QAClC,OAAO,IAAI,CAAC,kBAAkB,CAAC,IAAI,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,CAAC,CAAC;IAC1D,CAAC,CAAC,CAAC;AACL,CAAC","sourcesContent":["export function getMonthNames(lang: string): string[] {\n return new Array(12).fill(null).map((_, i) => {\n const date = new Date(2000, i, 1);\n return date.toLocaleDateString(lang, { month: 'long' });\n });\n}\n"]}
@@ -1,7 +1,7 @@
1
1
  import type { PropertyDeclarations } from 'lit-element';
2
2
  import type { HALJSONResource } from '../../public/NucleonElement/types';
3
3
  import type { TemplateResult } from 'lit-html';
4
- import type { Status } from './types';
4
+ import type { Badge, Status } from './types';
5
5
  import { BooleanSelector } from '@foxy.io/sdk/core';
6
6
  import { NucleonElement } from '../../public/NucleonElement/NucleonElement';
7
7
  declare const Base: typeof NucleonElement & {
@@ -34,9 +34,7 @@ export declare class InternalForm<TData extends HALJSONResource> extends Base<TD
34
34
  /** I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable. */
35
35
  get headerSubtitleOptions(): Record<string, unknown>;
36
36
  /** Getter that returns a list of the optional badges to put into the subtitle. The badges are shown only if subtitle is visible. */
37
- get headerSubtitleBadges(): {
38
- key: string;
39
- }[];
37
+ get headerSubtitleBadges(): Badge[];
40
38
  /** ID that will be written to clipboard when Copy ID button in header is clicked. */
41
39
  get headerCopyIdValue(): string | number;
42
40
  get hiddenSelector(): BooleanSelector;
@@ -87,8 +87,8 @@ export class InternalForm extends Base {
87
87
  return html `
88
88
  <div>
89
89
  ${this.renderTemplateOrSlot('header:before')}
90
- <h2>
91
- <span class="flex items-center gap-s leading-xs text-xl font-medium break-all">
90
+ <h2 class="grid gap-xs">
91
+ <span class="flex items-center gap-s leading-none text-xl font-medium break-all">
92
92
  <foxy-i18n
93
93
  options=${JSON.stringify(this.headerTitleOptions)}
94
94
  infer="header"
@@ -123,25 +123,33 @@ export class InternalForm extends Base {
123
123
  </span>
124
124
  ${data
125
125
  ? html `
126
- <div class="flex items-center gap-s text-secondary leading-s">
126
+ <div class="flex flex-wrap items-center gap-s leading-xs">
127
127
  ${this.headerSubtitleBadges.map(badge => {
128
+ var _a;
128
129
  return html `
129
- <foxy-i18n
130
- class="border border-contrast-60 font-medium uppercase tracking-wider block rounded-s px-xs text-xs"
131
- infer="header badges"
132
- key=${badge.key}
130
+ <span
131
+ data-testclass="badge"
132
+ class=${classMap({
133
+ 'inline-flex gap-xs items-center rounded-s px-xs': true,
134
+ [(_a = badge.class) !== null && _a !== void 0 ? _a : 'bg-contrast-5']: true,
135
+ })}
133
136
  >
134
- </foxy-i18n>
137
+ ${badge.icon}
138
+ ${'text' in badge
139
+ ? badge.text
140
+ : html `<foxy-i18n infer="header badges" key=${badge.key}></foxy-i18n>`}
141
+ </span>
135
142
  `;
136
143
  })}
137
144
  <foxy-i18n
138
145
  infer="header"
146
+ class="text-secondary"
139
147
  key=${this.headerSubtitleKey}
140
148
  .options=${this.headerSubtitleOptions}
141
149
  >
142
150
  </foxy-i18n>
143
151
  </div>
144
- ${actions ? html `<div class="mt-xs flex gap-m">${actions}</div>` : ''}
152
+ ${actions ? html `<div class="flex gap-x-m">${actions}</div>` : ''}
145
153
  `
146
154
  : ''}
147
155
  </h2>