@foxy.io/elements 1.27.0-beta.5 → 1.27.0-beta.6

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 (275) 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-api-browser.js +1 -1
  6. package/dist/cdn/foxy-applied-coupon-code-card.js +1 -1
  7. package/dist/cdn/foxy-applied-coupon-code-form.js +1 -1
  8. package/dist/cdn/foxy-applied-tax-card.js +1 -1
  9. package/dist/cdn/foxy-attribute-card.js +1 -1
  10. package/dist/cdn/foxy-attribute-form.js +1 -1
  11. package/dist/cdn/foxy-billing-address-card.js +1 -1
  12. package/dist/cdn/foxy-cancellation-form.js +1 -1
  13. package/dist/cdn/foxy-cart-card.js +1 -1
  14. package/dist/cdn/foxy-cart-form.js +1 -1
  15. package/dist/cdn/foxy-client-card.js +1 -1
  16. package/dist/cdn/foxy-client-form.js +1 -1
  17. package/dist/cdn/foxy-collection-page.js +1 -1
  18. package/dist/cdn/foxy-collection-pages.js +1 -1
  19. package/dist/cdn/foxy-copy-to-clipboard.js +1 -1
  20. package/dist/cdn/foxy-coupon-card.js +1 -1
  21. package/dist/cdn/foxy-coupon-code-card.js +1 -0
  22. package/dist/cdn/foxy-coupon-code-form.js +1 -1
  23. package/dist/cdn/foxy-coupon-codes-form.js +1 -1
  24. package/dist/cdn/foxy-coupon-detail-card.js +1 -1
  25. package/dist/cdn/foxy-coupon-form.js +1 -1
  26. package/dist/cdn/foxy-custom-field-card.js +1 -1
  27. package/dist/cdn/foxy-custom-field-form.js +1 -1
  28. package/dist/cdn/foxy-customer-api.js +1 -1
  29. package/dist/cdn/foxy-customer-card.js +1 -1
  30. package/dist/cdn/foxy-customer-form.js +1 -1
  31. package/dist/cdn/foxy-customer-portal-settings-form.js +1 -1
  32. package/dist/cdn/foxy-customer-portal-settings.js +1 -1
  33. package/dist/cdn/foxy-customer-portal.js +2 -2
  34. package/dist/cdn/foxy-customer.js +1 -1
  35. package/dist/cdn/foxy-customers-table.js +1 -1
  36. package/dist/cdn/foxy-discount-builder.js +1 -1
  37. package/dist/cdn/foxy-discount-card.js +1 -1
  38. package/dist/cdn/foxy-discount-detail-card.js +1 -1
  39. package/dist/cdn/foxy-donation.js +1 -1
  40. package/dist/cdn/foxy-downloadable-card.js +1 -1
  41. package/dist/cdn/foxy-downloadable-form.js +2 -2
  42. package/dist/cdn/foxy-email-template-card.js +1 -1
  43. package/dist/cdn/foxy-email-template-form.js +1 -1
  44. package/dist/cdn/foxy-error-entry-card.js +1 -1
  45. package/dist/cdn/foxy-filter-attribute-card.js +1 -1
  46. package/dist/cdn/foxy-filter-attribute-form.js +1 -1
  47. package/dist/cdn/foxy-form-dialog.js +1 -1
  48. package/dist/cdn/foxy-generate-codes-form.js +1 -1
  49. package/dist/cdn/foxy-gift-card-card.js +1 -1
  50. package/dist/cdn/foxy-gift-card-code-form.js +1 -1
  51. package/dist/cdn/foxy-gift-card-code-log-card.js +1 -1
  52. package/dist/cdn/foxy-gift-card-codes-form.js +1 -1
  53. package/dist/cdn/foxy-gift-card-form.js +1 -1
  54. package/dist/cdn/foxy-i18n-editor.js +2 -2
  55. package/dist/cdn/foxy-i18n.js +1 -1
  56. package/dist/cdn/foxy-integration-card.js +1 -1
  57. package/dist/cdn/foxy-integration-form.js +1 -1
  58. package/dist/cdn/foxy-item-card.js +1 -1
  59. package/dist/cdn/foxy-item-category-card.js +1 -1
  60. package/dist/cdn/foxy-item-category-form.js +1 -1
  61. package/dist/cdn/foxy-item-form.js +3 -3
  62. package/dist/cdn/foxy-item-option-card.js +1 -1
  63. package/dist/cdn/foxy-item-option-form.js +1 -1
  64. package/dist/cdn/foxy-items-form.js +1 -1
  65. package/dist/cdn/foxy-native-integration-card.js +1 -1
  66. package/dist/cdn/foxy-native-integration-form.js +1 -1
  67. package/dist/cdn/foxy-nucleon-element.js +1 -1
  68. package/dist/cdn/foxy-pagination.js +1 -1
  69. package/dist/cdn/foxy-passkey-card.js +1 -1
  70. package/dist/cdn/foxy-passkey-form.js +1 -1
  71. package/dist/cdn/foxy-payment-card.js +1 -1
  72. package/dist/cdn/foxy-payment-method-card.js +1 -1
  73. package/dist/cdn/foxy-payments-api-fraud-protection-card.js +1 -1
  74. package/dist/cdn/foxy-payments-api-fraud-protection-form.js +1 -1
  75. package/dist/cdn/foxy-payments-api-payment-method-card.js +1 -1
  76. package/dist/cdn/foxy-payments-api-payment-method-form.js +1 -1
  77. package/dist/cdn/foxy-payments-api-payment-preset-card.js +1 -1
  78. package/dist/cdn/foxy-payments-api-payment-preset-form.js +1 -1
  79. package/dist/cdn/foxy-query-builder.js +1 -1
  80. package/dist/cdn/foxy-report-form.js +1 -1
  81. package/dist/cdn/foxy-reports-table.js +1 -1
  82. package/dist/cdn/foxy-shipment-card.js +1 -1
  83. package/dist/cdn/foxy-shipping-method-card.js +1 -1
  84. package/dist/cdn/foxy-sign-in-form.js +1 -1
  85. package/dist/cdn/foxy-spinner.js +1 -1
  86. package/dist/cdn/foxy-store-card.js +1 -1
  87. package/dist/cdn/foxy-store-form.js +1 -1
  88. package/dist/cdn/foxy-store-shipping-method-form.js +1 -1
  89. package/dist/cdn/foxy-subscription-card.js +1 -1
  90. package/dist/cdn/foxy-subscription-form.js +1 -1
  91. package/dist/cdn/foxy-subscription-settings-form.js +1 -1
  92. package/dist/cdn/foxy-subscriptions-table.js +1 -1
  93. package/dist/cdn/foxy-table.js +1 -1
  94. package/dist/cdn/foxy-tax-card.js +1 -1
  95. package/dist/cdn/foxy-tax-form.js +1 -1
  96. package/dist/cdn/foxy-template-config-form.js +1 -1
  97. package/dist/cdn/foxy-template-form.js +1 -1
  98. package/dist/cdn/foxy-template-set-card.js +1 -1
  99. package/dist/cdn/foxy-template-set-form.js +1 -1
  100. package/dist/cdn/foxy-transaction-card.js +1 -1
  101. package/dist/cdn/foxy-transaction.js +1 -1
  102. package/dist/cdn/foxy-transactions-table.js +1 -1
  103. package/dist/cdn/foxy-user-card.js +1 -1
  104. package/dist/cdn/foxy-user-form.js +1 -1
  105. package/dist/cdn/foxy-users-table.js +1 -1
  106. package/dist/cdn/foxy-webhook-card.js +1 -1
  107. package/dist/cdn/foxy-webhook-form.js +1 -1
  108. package/dist/cdn/foxy-webhook-log-card.js +1 -1
  109. package/dist/cdn/foxy-webhook-status-card.js +1 -1
  110. package/dist/cdn/{shared-20c4310b.js → shared-065dbdf6.js} +1 -1
  111. package/dist/cdn/{shared-0f49d9c3.js → shared-07d5e225.js} +1 -1
  112. package/dist/cdn/{shared-82435697.js → shared-0e8dceb8.js} +1 -1
  113. package/dist/cdn/{shared-6ef4ce19.js → shared-1a9e80fa.js} +1 -1
  114. package/dist/cdn/{shared-e4e0dc11.js → shared-1d6beb48.js} +1 -1
  115. package/dist/cdn/shared-208e37af.js +88 -0
  116. package/dist/cdn/shared-29f2468c.js +6 -0
  117. package/dist/cdn/shared-400240f8.js +1 -0
  118. package/dist/cdn/{shared-9db9528b.js → shared-589e5d06.js} +15 -15
  119. package/dist/cdn/{shared-6be0a096.js → shared-5dbb9630.js} +1 -1
  120. package/dist/cdn/{shared-6350f7d9.js → shared-5e35c5a5.js} +1 -1
  121. package/dist/cdn/{shared-3cbcd9cb.js → shared-5f09205d.js} +1 -1
  122. package/dist/cdn/{shared-d15c3e2d.js → shared-61f67b16.js} +1 -1
  123. package/dist/cdn/shared-683145e5.js +1 -0
  124. package/dist/cdn/shared-6c4affb9.js +1 -0
  125. package/dist/cdn/{shared-4fb9d21f.js → shared-77fd8dae.js} +1 -1
  126. package/dist/cdn/{shared-92cdd504.js → shared-80eb1fee.js} +1 -1
  127. package/dist/cdn/shared-850e2ae1.js +10 -0
  128. package/dist/cdn/{shared-872151f5.js → shared-85979316.js} +1 -1
  129. package/dist/cdn/{shared-4fd17baf.js → shared-8def6325.js} +1 -1
  130. package/dist/cdn/{shared-18d109f5.js → shared-93812e51.js} +1 -1
  131. package/dist/cdn/{shared-6a998243.js → shared-9a5da74d.js} +21 -27
  132. package/dist/cdn/{shared-e52280d9.js → shared-b30f9b10.js} +1 -1
  133. package/dist/cdn/shared-bb08b5ce.js +32 -0
  134. package/dist/cdn/{shared-89b42eef.js → shared-bba8ae80.js} +1 -1
  135. package/dist/cdn/{shared-bf132324.js → shared-befe135a.js} +1 -1
  136. package/dist/cdn/{shared-7ff496f6.js → shared-bfa30d93.js} +1 -1
  137. package/dist/cdn/shared-c5f57aa8.js +1 -0
  138. package/dist/cdn/{shared-3277bbf5.js → shared-ca15d510.js} +1 -1
  139. package/dist/cdn/{shared-46454866.js → shared-cab2aa63.js} +4 -4
  140. package/dist/cdn/shared-cc723108.js +12 -0
  141. package/dist/cdn/{shared-97793410.js → shared-d04c2e0c.js} +1 -1
  142. package/dist/cdn/{shared-59a5edee.js → shared-da7a0bfb.js} +9 -9
  143. package/dist/cdn/shared-e35297c9.js +1 -0
  144. package/dist/cdn/{shared-8778d784.js → shared-e48fbf50.js} +1 -1
  145. package/dist/cdn/shared-e84be1c2.js +64 -0
  146. package/dist/cdn/{shared-8dd03329.js → shared-e966f1ef.js} +1 -1
  147. package/dist/cdn/{shared-1122a125.js → shared-fb8c09b8.js} +1 -1
  148. package/dist/cdn/{shared-fcaf15e5.js → shared-fd041b18.js} +1 -1
  149. package/dist/cdn/{shared-1b0992cc.js → shared-fda63db8.js} +5 -5
  150. package/dist/cdn/{shared-51ac503d.js → shared-fe7b3ed2.js} +1 -1
  151. package/dist/cdn/translations/coupon-code-card/en.json +11 -0
  152. package/dist/cdn/translations/coupon-form/en.json +522 -297
  153. package/dist/elements/internal/InternalAsyncListControl/InternalAsyncListControl.d.ts +10 -0
  154. package/dist/elements/internal/InternalAsyncListControl/InternalAsyncListControl.js +81 -2
  155. package/dist/elements/internal/InternalAsyncListControl/InternalAsyncListControl.js.map +1 -1
  156. package/dist/elements/internal/InternalAsyncListControl/InternalAsyncListControlFilterOverlay.d.ts +11 -0
  157. package/dist/elements/internal/InternalAsyncListControl/InternalAsyncListControlFilterOverlay.js +57 -0
  158. package/dist/elements/internal/InternalAsyncListControl/InternalAsyncListControlFilterOverlay.js.map +1 -0
  159. package/dist/elements/internal/InternalAsyncListControl/index.d.ts +1 -0
  160. package/dist/elements/internal/InternalAsyncListControl/index.js +3 -0
  161. package/dist/elements/internal/InternalAsyncListControl/index.js.map +1 -1
  162. package/dist/elements/internal/InternalAsyncListControl/types.d.ts +8 -0
  163. package/dist/elements/internal/InternalAsyncListControl/types.js +2 -0
  164. package/dist/elements/internal/InternalAsyncListControl/types.js.map +1 -0
  165. package/dist/elements/internal/InternalAsyncResourceLinkListControl/InternalAsyncResourceLinkListControl.d.ts +23 -0
  166. package/dist/elements/internal/InternalAsyncResourceLinkListControl/InternalAsyncResourceLinkListControl.js +224 -0
  167. package/dist/elements/internal/InternalAsyncResourceLinkListControl/InternalAsyncResourceLinkListControl.js.map +1 -0
  168. package/dist/elements/internal/InternalAsyncResourceLinkListControl/index.d.ts +8 -0
  169. package/dist/elements/internal/InternalAsyncResourceLinkListControl/index.js +10 -0
  170. package/dist/elements/internal/InternalAsyncResourceLinkListControl/index.js.map +1 -0
  171. package/dist/elements/internal/InternalForm/InternalForm.d.ts +10 -0
  172. package/dist/elements/internal/InternalForm/InternalForm.js +44 -0
  173. package/dist/elements/internal/InternalForm/InternalForm.js.map +1 -1
  174. package/dist/elements/internal/InternalForm/index.d.ts +2 -0
  175. package/dist/elements/internal/InternalForm/index.js +2 -0
  176. package/dist/elements/internal/InternalForm/index.js.map +1 -1
  177. package/dist/elements/internal/InternalIntegerControl/InternalIntegerControl.d.ts +1 -0
  178. package/dist/elements/internal/InternalIntegerControl/InternalIntegerControl.js +3 -0
  179. package/dist/elements/internal/InternalIntegerControl/InternalIntegerControl.js.map +1 -1
  180. package/dist/elements/internal/InternalQueryBuilderControl/InternalQueryBuilderControl.d.ts +10 -0
  181. package/dist/elements/internal/InternalQueryBuilderControl/InternalQueryBuilderControl.js +51 -0
  182. package/dist/elements/internal/InternalQueryBuilderControl/InternalQueryBuilderControl.js.map +1 -0
  183. package/dist/elements/internal/InternalQueryBuilderControl/index.d.ts +4 -0
  184. package/dist/elements/internal/InternalQueryBuilderControl/index.js +6 -0
  185. package/dist/elements/internal/InternalQueryBuilderControl/index.js.map +1 -0
  186. package/dist/elements/public/CartForm/CartForm.js +81 -81
  187. package/dist/elements/public/CartForm/CartForm.js.map +1 -1
  188. package/dist/elements/public/CouponCodeCard/CouponCodeCard.d.ts +16 -0
  189. package/dist/elements/public/CouponCodeCard/CouponCodeCard.js +41 -0
  190. package/dist/elements/public/CouponCodeCard/CouponCodeCard.js.map +1 -0
  191. package/dist/elements/public/CouponCodeCard/index.d.ts +4 -0
  192. package/dist/elements/public/CouponCodeCard/index.js +6 -0
  193. package/dist/elements/public/CouponCodeCard/index.js.map +1 -0
  194. package/dist/elements/public/CouponCodeCard/types.d.ts +3 -0
  195. package/dist/elements/public/CouponCodeCard/types.js +2 -0
  196. package/dist/elements/public/CouponCodeCard/types.js.map +1 -0
  197. package/dist/elements/public/CouponForm/CouponForm.d.ts +65 -41
  198. package/dist/elements/public/CouponForm/CouponForm.js +320 -1035
  199. package/dist/elements/public/CouponForm/CouponForm.js.map +1 -1
  200. package/dist/elements/public/CouponForm/index.d.ts +15 -16
  201. package/dist/elements/public/CouponForm/index.js +15 -16
  202. package/dist/elements/public/CouponForm/index.js.map +1 -1
  203. package/dist/elements/public/CouponForm/internal/InternalCouponFormBulkAddControl/InternalCouponFormBulkAddControl.d.ts +9 -0
  204. package/dist/elements/public/CouponForm/internal/InternalCouponFormBulkAddControl/InternalCouponFormBulkAddControl.js +49 -0
  205. package/dist/elements/public/CouponForm/internal/InternalCouponFormBulkAddControl/InternalCouponFormBulkAddControl.js.map +1 -0
  206. package/dist/elements/public/CouponForm/internal/InternalCouponFormBulkAddControl/index.d.ts +6 -0
  207. package/dist/elements/public/CouponForm/internal/InternalCouponFormBulkAddControl/index.js +8 -0
  208. package/dist/elements/public/CouponForm/internal/InternalCouponFormBulkAddControl/index.js.map +1 -0
  209. package/dist/elements/public/CouponForm/internal/InternalCouponFormRulesControl/InternalCouponFormRulesControl.d.ts +7 -0
  210. package/dist/elements/public/CouponForm/internal/InternalCouponFormRulesControl/InternalCouponFormRulesControl.js +141 -0
  211. package/dist/elements/public/CouponForm/internal/InternalCouponFormRulesControl/InternalCouponFormRulesControl.js.map +1 -0
  212. package/dist/elements/public/CouponForm/internal/InternalCouponFormRulesControl/index.d.ts +6 -0
  213. package/dist/elements/public/CouponForm/internal/InternalCouponFormRulesControl/index.js +8 -0
  214. package/dist/elements/public/CouponForm/internal/InternalCouponFormRulesControl/index.js.map +1 -0
  215. package/dist/elements/public/CouponForm/types.d.ts +10 -1
  216. package/dist/elements/public/CouponForm/types.js.map +1 -1
  217. package/dist/elements/public/CustomerPortalSettingsForm/CustomerPortalSettingsForm.js +7 -3
  218. package/dist/elements/public/CustomerPortalSettingsForm/CustomerPortalSettingsForm.js.map +1 -1
  219. package/dist/elements/public/CustomerPortalSettingsForm/toOrigin.d.ts +1 -0
  220. package/dist/elements/public/CustomerPortalSettingsForm/toOrigin.js +9 -0
  221. package/dist/elements/public/CustomerPortalSettingsForm/toOrigin.js.map +1 -0
  222. package/dist/elements/public/DownloadableForm/DownloadableForm.js +9 -9
  223. package/dist/elements/public/DownloadableForm/DownloadableForm.js.map +1 -1
  224. package/dist/elements/public/I18n/format/discount.js +9 -2
  225. package/dist/elements/public/I18n/format/discount.js.map +1 -1
  226. package/dist/elements/public/I18n/format/ordinal.js +6 -2
  227. package/dist/elements/public/I18n/format/ordinal.js.map +1 -1
  228. package/dist/elements/public/IntegrationForm/IntegrationForm.js +8 -6
  229. package/dist/elements/public/IntegrationForm/IntegrationForm.js.map +1 -1
  230. package/dist/elements/public/ItemCategoryForm/ItemCategoryForm.js +27 -27
  231. package/dist/elements/public/ItemCategoryForm/ItemCategoryForm.js.map +1 -1
  232. package/dist/elements/public/QueryBuilder/QueryBuilder.d.ts +4 -0
  233. package/dist/elements/public/QueryBuilder/QueryBuilder.js +10 -2
  234. package/dist/elements/public/QueryBuilder/QueryBuilder.js.map +1 -1
  235. package/dist/elements/public/QueryBuilder/components/Group.d.ts +3 -1
  236. package/dist/elements/public/QueryBuilder/components/Group.js +8 -1
  237. package/dist/elements/public/QueryBuilder/components/Group.js.map +1 -1
  238. package/dist/elements/public/QueryBuilder/components/OperatorToggle.d.ts +2 -1
  239. package/dist/elements/public/QueryBuilder/components/OperatorToggle.js +5 -4
  240. package/dist/elements/public/QueryBuilder/components/OperatorToggle.js.map +1 -1
  241. package/dist/elements/public/QueryBuilder/components/Rule.d.ts +3 -1
  242. package/dist/elements/public/QueryBuilder/components/Rule.js +2 -1
  243. package/dist/elements/public/QueryBuilder/components/Rule.js.map +1 -1
  244. package/dist/elements/public/StoreForm/StoreForm.js +7 -8
  245. package/dist/elements/public/StoreForm/StoreForm.js.map +1 -1
  246. package/dist/elements/public/TemplateSetForm/TemplateSetForm.js +28 -28
  247. package/dist/elements/public/TemplateSetForm/TemplateSetForm.js.map +1 -1
  248. package/dist/elements/public/index.d.ts +1 -0
  249. package/dist/elements/public/index.defined.d.ts +1 -0
  250. package/dist/elements/public/index.defined.js +1 -0
  251. package/dist/elements/public/index.defined.js.map +1 -1
  252. package/dist/elements/public/index.js +1 -0
  253. package/dist/elements/public/index.js.map +1 -1
  254. package/dist/mixins/inferrable.js +8 -3
  255. package/dist/mixins/inferrable.js.map +1 -1
  256. package/package.json +1 -1
  257. package/dist/cdn/shared-20f65e73.js +0 -1
  258. package/dist/cdn/shared-27c7514d.js +0 -1
  259. package/dist/cdn/shared-669decee.js +0 -1
  260. package/dist/cdn/shared-afefe2ac.js +0 -113
  261. package/dist/cdn/shared-b33fd700.js +0 -1
  262. package/dist/cdn/shared-b51b9df7.js +0 -64
  263. package/dist/cdn/shared-b914895b.js +0 -1
  264. package/dist/cdn/shared-cce18690.js +0 -1
  265. package/dist/cdn/shared-d04dd602.js +0 -20
  266. package/dist/cdn/shared-df58b901.js +0 -1
  267. package/dist/elements/public/CouponForm/private/CategoryRestrictionsPage.d.ts +0 -20
  268. package/dist/elements/public/CouponForm/private/CategoryRestrictionsPage.js +0 -99
  269. package/dist/elements/public/CouponForm/private/CategoryRestrictionsPage.js.map +0 -1
  270. package/dist/elements/public/CouponForm/private/CategoryRestrictionsPageItem.d.ts +0 -18
  271. package/dist/elements/public/CouponForm/private/CategoryRestrictionsPageItem.js +0 -50
  272. package/dist/elements/public/CouponForm/private/CategoryRestrictionsPageItem.js.map +0 -1
  273. package/dist/elements/public/CouponForm/private/CategoryRestrictionsPageItemContent.d.ts +0 -18
  274. package/dist/elements/public/CouponForm/private/CategoryRestrictionsPageItemContent.js +0 -53
  275. package/dist/elements/public/CouponForm/private/CategoryRestrictionsPageItemContent.js.map +0 -1
@@ -1 +1 @@
1
- import"./shared-9db9528b.js";import{I as e}from"./shared-bf132324.js";import{_ as r}from"./shared-11014aad.js";import{s as t}from"./shared-79d0699c.js";import{p as a}from"./shared-43e2c3f6.js";import{i as s}from"./shared-9803aa7c.js";import{h as i}from"./shared-dc73b9a5.js";let l,o=e=>e;customElements.define("foxy-internal-date-control",class extends e{constructor(){super(...arguments),this.format=null}static get properties(){return r(r({},super.properties),{},{format:{type:String}})}renderControl(){var e;let r;return r="unix"===this.format?t(new Date(1e3*(null!==(e=this._value)&&void 0!==e?e:0))):this._value,i(l||(l=o` <vaadin-date-picker error-message="${0}" placeholder="${0}" helper-text="${0}" label="${0}" class="w-full" ?disabled="${0}" ?readonly="${0}" .checkValidity="${0}" .value="${0}" @keydown="${0}" @change="${0}"> </vaadin-date-picker> `),s(this._errorMessage),this.placeholder,this.helperText,this.label,this.disabled,this.readonly,this._checkValidity,r,(e=>{var r;return"Enter"===e.key&&(null===(r=this.nucleon)||void 0===r?void 0:r.submit())}),(e=>{var r,t;const s=e.currentTarget;"unix"===this.format?this._value=Math.floor((null!==(t=null===(r=a(s.value))||void 0===r?void 0:r.getTime())&&void 0!==t?t:0)/1e3):this._value=s.value}))}});
1
+ import"./shared-589e5d06.js";import{I as e}from"./shared-befe135a.js";import{_ as r}from"./shared-11014aad.js";import{s as t}from"./shared-79d0699c.js";import{p as a}from"./shared-43e2c3f6.js";import{i as s}from"./shared-9803aa7c.js";import{h as i}from"./shared-dc73b9a5.js";let l,o=e=>e;customElements.define("foxy-internal-date-control",class extends e{constructor(){super(...arguments),this.format=null}static get properties(){return r(r({},super.properties),{},{format:{type:String}})}renderControl(){var e;let r;return r="unix"===this.format?t(new Date(1e3*(null!==(e=this._value)&&void 0!==e?e:0))):this._value,i(l||(l=o` <vaadin-date-picker error-message="${0}" placeholder="${0}" helper-text="${0}" label="${0}" class="w-full" ?disabled="${0}" ?readonly="${0}" .checkValidity="${0}" .value="${0}" @keydown="${0}" @change="${0}"> </vaadin-date-picker> `),s(this._errorMessage),this.placeholder,this.helperText,this.label,this.disabled,this.readonly,this._checkValidity,r,(e=>{var r;return"Enter"===e.key&&(null===(r=this.nucleon)||void 0===r?void 0:r.submit())}),(e=>{var r,t;const s=e.currentTarget;"unix"===this.format?this._value=Math.floor((null!==(t=null===(r=a(s.value))||void 0===r?void 0:r.getTime())&&void 0!==t?t:0)/1e3):this._value=s.value}))}});
@@ -1,4 +1,4 @@
1
- import{E as t,T as e}from"./shared-4877ed05.js";import{h as o,P as r}from"./shared-48b76c74.js";import"./shared-205721a3.js";import{L as a}from"./shared-724e9a20.js";import{a as i,I as s}from"./shared-d04dd602.js";import{I as n}from"./shared-651c44fa.js";import{a as l}from"./shared-7e201abd.js";const c=o`<dom-module id="lumo-tab" theme-for="vaadin-tab">
1
+ import{E as t,T as e}from"./shared-4877ed05.js";import{h as o,P as r}from"./shared-48b76c74.js";import"./shared-205721a3.js";import{L as a}from"./shared-724e9a20.js";import{I as i}from"./shared-cc723108.js";import{I as s}from"./shared-651c44fa.js";import{a as n}from"./shared-850e2ae1.js";import{a as l}from"./shared-7e201abd.js";const c=o`<dom-module id="lumo-tab" theme-for="vaadin-tab">
2
2
  <template>
3
3
  <style>
4
4
  :host {
@@ -226,7 +226,7 @@ import{E as t,T as e}from"./shared-4877ed05.js";import{h as o,P as r}from"./shar
226
226
  Copyright (c) 2017 Vaadin Ltd.
227
227
  This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
228
228
  */
229
- class d extends(t(e(n(r)))){static get template(){return o`
229
+ class d extends(t(e(s(r)))){static get template(){return o`
230
230
  <slot></slot>
231
231
  `}static get is(){return"vaadin-tab"}static get version(){return"3.2.0"}ready(){super.ready(),this.setAttribute("role","tab")}_onKeyup(t){const e=this.hasAttribute("active");if(super._onKeyup(t),e){const t=this.querySelector("a");t&&t.click()}}}customElements.define(d.is,d);const m=o`<dom-module id="lumo-tabs" theme-for="vaadin-tabs">
232
232
  <template>
@@ -464,7 +464,7 @@ class d extends(t(e(n(r)))){static get template(){return o`
464
464
  Copyright (c) 2017 Vaadin Ltd.
465
465
  This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
466
466
  */
467
- const h=/Apple.* Version\/(9|10)/.test(navigator.userAgent);class f extends(t(a(e(l([s],r))))){static get template(){return o`
467
+ const h=/Apple.* Version\/(9|10)/.test(navigator.userAgent);class f extends(t(a(e(l([i],r))))){static get template(){return o`
468
468
  <style>
469
469
  :host {
470
470
  display: flex;
@@ -550,4 +550,4 @@ const h=/Apple.* Version\/(9|10)/.test(navigator.userAgent);class f extends(t(a(
550
550
  </div>
551
551
 
552
552
  <div on-click="_scrollForward" part="forward-button"></div>
553
- `}static get is(){return"vaadin-tabs"}static get version(){return"3.2.0"}static get properties(){return{orientation:{value:"horizontal",type:String},selected:{value:0,type:Number}}}static get observers(){return["_updateOverflow(items.*, vertical)"]}ready(){super.ready(),this.addEventListener("iron-resize",(()=>this._updateOverflow())),this._scrollerElement.addEventListener("scroll",(()=>this._updateOverflow())),this.setAttribute("role","tablist"),i(this,(()=>{this._updateOverflow()}))}_scrollForward(){this._scroll(-this.__direction*this._scrollOffset)}_scrollBack(){this._scroll(this.__direction*this._scrollOffset)}get _scrollOffset(){return this._vertical?this._scrollerElement.offsetHeight:this._scrollerElement.offsetWidth}get _scrollerElement(){return this.$.scroll}get __direction(){return this._vertical||"rtl"!==this.getAttribute("dir")?-1:1}_updateOverflow(){const t=this._vertical?this._scrollerElement.scrollTop:this.__getNormalizedScrollLeft(this._scrollerElement);let e=this._vertical?this._scrollerElement.scrollHeight:this._scrollerElement.scrollWidth;e-=1;let o=t>0?"start":"";o+=t+this._scrollOffset<e?" end":"",1==this.__direction&&(o=o.replace(/start|end/gi,(t=>"start"===t?"end":"start"))),o?this.setAttribute("overflow",o.trim()):this.removeAttribute("overflow"),this._repaintShadowNodesHack()}_repaintShadowNodesHack(){if(h&&this.root){const t="-webkit-backface-visibility";this.root.querySelectorAll("*").forEach((e=>{e.style[t]="visible",e.style[t]=""}))}}}customElements.define(f.is,f);
553
+ `}static get is(){return"vaadin-tabs"}static get version(){return"3.2.0"}static get properties(){return{orientation:{value:"horizontal",type:String},selected:{value:0,type:Number}}}static get observers(){return["_updateOverflow(items.*, vertical)"]}ready(){super.ready(),this.addEventListener("iron-resize",(()=>this._updateOverflow())),this._scrollerElement.addEventListener("scroll",(()=>this._updateOverflow())),this.setAttribute("role","tablist"),n(this,(()=>{this._updateOverflow()}))}_scrollForward(){this._scroll(-this.__direction*this._scrollOffset)}_scrollBack(){this._scroll(this.__direction*this._scrollOffset)}get _scrollOffset(){return this._vertical?this._scrollerElement.offsetHeight:this._scrollerElement.offsetWidth}get _scrollerElement(){return this.$.scroll}get __direction(){return this._vertical||"rtl"!==this.getAttribute("dir")?-1:1}_updateOverflow(){const t=this._vertical?this._scrollerElement.scrollTop:this.__getNormalizedScrollLeft(this._scrollerElement);let e=this._vertical?this._scrollerElement.scrollHeight:this._scrollerElement.scrollWidth;e-=1;let o=t>0?"start":"";o+=t+this._scrollOffset<e?" end":"",1==this.__direction&&(o=o.replace(/start|end/gi,(t=>"start"===t?"end":"start"))),o?this.setAttribute("overflow",o.trim()):this.removeAttribute("overflow"),this._repaintShadowNodesHack()}_repaintShadowNodesHack(){if(h&&this.root){const t="-webkit-backface-visibility";this.root.querySelectorAll("*").forEach((e=>{e.style[t]="visible",e.style[t]=""}))}}}customElements.define(f.is,f);
@@ -0,0 +1,12 @@
1
+ import{d as e}from"./shared-7e201abd.js";import{u as i}from"./shared-56addb06.js";
2
+ /**
3
+ @license
4
+ Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
5
+ This code may only be used under the BSD style license found at
6
+ http://polymer.github.io/LICENSE.txt The complete set of authors may be found at
7
+ http://polymer.github.io/AUTHORS.txt The complete set of contributors may be
8
+ found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by Google as
9
+ part of the polymer project is also subject to an additional IP rights grant
10
+ found at http://polymer.github.io/PATENTS.txt
11
+ */
12
+ var t=new Set;const s={properties:{_parentResizable:{type:Object,observer:"_parentResizableChanged"},_notifyingDescendant:{type:Boolean,value:!1}},listeners:{"iron-request-resize-notifications":"_onIronRequestResizeNotifications"},created:function(){this._interestedResizables=[],this._boundNotifyResize=this.notifyResize.bind(this),this._boundOnDescendantIronResize=this._onDescendantIronResize.bind(this)},attached:function(){this._requestResizeNotifications()},detached:function(){this._parentResizable?this._parentResizable.stopResizeNotificationsFor(this):(t.delete(this),window.removeEventListener("resize",this._boundNotifyResize)),this._parentResizable=null},notifyResize:function(){this.isAttached&&(this._interestedResizables.forEach((function(e){this.resizerShouldNotify(e)&&this._notifyDescendant(e)}),this),this._fireResize())},assignParentResizable:function(e){this._parentResizable&&this._parentResizable.stopResizeNotificationsFor(this),this._parentResizable=e,e&&-1===e._interestedResizables.indexOf(this)&&(e._interestedResizables.push(this),e._subscribeIronResize(this))},stopResizeNotificationsFor:function(e){var i=this._interestedResizables.indexOf(e);i>-1&&(this._interestedResizables.splice(i,1),this._unsubscribeIronResize(e))},_subscribeIronResize:function(e){e.addEventListener("iron-resize",this._boundOnDescendantIronResize)},_unsubscribeIronResize:function(e){e.removeEventListener("iron-resize",this._boundOnDescendantIronResize)},resizerShouldNotify:function(e){return!0},_onDescendantIronResize:function(e){this._notifyingDescendant?e.stopPropagation():i||this._fireResize()},_fireResize:function(){this.fire("iron-resize",null,{node:this,bubbles:!1})},_onIronRequestResizeNotifications:function(i){var t=e(i).rootTarget;t!==this&&(t.assignParentResizable(this),this._notifyDescendant(t),i.stopPropagation())},_parentResizableChanged:function(e){e&&window.removeEventListener("resize",this._boundNotifyResize)},_notifyDescendant:function(e){this.isAttached&&(this._notifyingDescendant=!0,e.notifyResize(),this._notifyingDescendant=!1)},_requestResizeNotifications:function(){if(this.isAttached)if("loading"===document.readyState){var e=this._requestResizeNotifications.bind(this);document.addEventListener("readystatechange",(function i(){document.removeEventListener("readystatechange",i),e()}))}else this._findParent(),this._parentResizable?this._parentResizable._interestedResizables.forEach((function(e){e!==this&&e._findParent()}),this):(t.forEach((function(e){e!==this&&e._findParent()}),this),window.addEventListener("resize",this._boundNotifyResize),this.notifyResize())},_findParent:function(){this.assignParentResizable(null),this.fire("iron-request-resize-notifications",null,{node:this,bubbles:!0,cancelable:!0}),this._parentResizable?t.delete(this):t.add(this)}};export{s as I};
@@ -1 +1 @@
1
- import"./shared-6a998243.js";import{I as e}from"./shared-bf132324.js";import{_ as t}from"./shared-11014aad.js";import{i as a}from"./shared-9803aa7c.js";import{h as s}from"./shared-dc73b9a5.js";import{A as i}from"./shared-e07b24ca.js";let r,l=e=>e;customElements.define("foxy-internal-async-combo-box-control",class extends e{constructor(){var e;super(...arguments),e=this,this.allowCustomValue=!1,this.itemLabelPath=null,this.itemValuePath=null,this.selectedItem=void 0,this.first=null,this.__dataProvider=async function(t,a){if(!e.first)return a([],0);const s=new URL(e.first);s.searchParams.set("offset",String(t.page*t.pageSize)),s.searchParams.set("limit",String(t.pageSize)),t.filter&&e.itemLabelPath&&s.searchParams.set(e.itemLabelPath,`*${t.filter}*`);const r=await new i(e).fetch(s.toString());if(!r.ok)throw new Error(await r.text());const l=await r.json();a(Array.from(Object.values(l._embedded))[0],l.total_items)}}static get properties(){return t(t({},super.properties),{},{allowCustomValue:{type:Boolean,attribute:"allow-custom-value"},itemLabelPath:{type:String,attribute:"item-label-path"},itemValuePath:{type:String,attribute:"item-value-path"},selectedItem:{attribute:!1},first:{type:String}})}renderControl(){var e,t;return s(r||(r=l` <vaadin-combo-box item-value-path="${0}" item-label-path="${0}" error-message="${0}" item-id-path="_links.self.href" helper-text="${0}" placeholder="${0}" label="${0}" class="w-full" ?allow-custom-value="${0}" ?disabled="${0}" ?readonly="${0}" clear-button-visible .checkValidity="${0}" .dataProvider="${0}" .selectedItem="${0}" .value="${0}" @change="${0}"> </vaadin-combo-box> `),a(null!==(e=this.itemValuePath)&&void 0!==e?e:void 0),a(null!==(t=this.itemLabelPath)&&void 0!==t?t:void 0),a(this._errorMessage),this.helperText,this.placeholder,this.label,this.allowCustomValue,this.disabled,this.readonly,this._checkValidity,this.__dataProvider,this.selectedItem,this._value,(e=>{e.stopPropagation();const t=e.currentTarget;this._value=t.value,this._value===t.value?(this.selectedItem=t.selectedItem,this.dispatchEvent(new CustomEvent("selected-item-changed"))):t.value=this._value}))}updated(e){if(super.updated(e),e.has("first")||e.has("itemLabelPath")){const e=this.renderRoot.querySelector("vaadin-combo-box");e&&(e.size=0,e.size=1)}}get _value(){var e;return null!==(e=super._value)&&void 0!==e?e:""}set _value(e){super._value=e}});
1
+ import"./shared-9a5da74d.js";import{I as e}from"./shared-befe135a.js";import{_ as t}from"./shared-11014aad.js";import{i as a}from"./shared-9803aa7c.js";import{h as s}from"./shared-dc73b9a5.js";import{A as i}from"./shared-e07b24ca.js";let r,l=e=>e;customElements.define("foxy-internal-async-combo-box-control",class extends e{constructor(){var e;super(...arguments),e=this,this.allowCustomValue=!1,this.itemLabelPath=null,this.itemValuePath=null,this.selectedItem=void 0,this.first=null,this.__dataProvider=async function(t,a){if(!e.first)return a([],0);const s=new URL(e.first);s.searchParams.set("offset",String(t.page*t.pageSize)),s.searchParams.set("limit",String(t.pageSize)),t.filter&&e.itemLabelPath&&s.searchParams.set(e.itemLabelPath,`*${t.filter}*`);const r=await new i(e).fetch(s.toString());if(!r.ok)throw new Error(await r.text());const l=await r.json();a(Array.from(Object.values(l._embedded))[0],l.total_items)}}static get properties(){return t(t({},super.properties),{},{allowCustomValue:{type:Boolean,attribute:"allow-custom-value"},itemLabelPath:{type:String,attribute:"item-label-path"},itemValuePath:{type:String,attribute:"item-value-path"},selectedItem:{attribute:!1},first:{type:String}})}renderControl(){var e,t;return s(r||(r=l` <vaadin-combo-box item-value-path="${0}" item-label-path="${0}" error-message="${0}" item-id-path="_links.self.href" helper-text="${0}" placeholder="${0}" label="${0}" class="w-full" ?allow-custom-value="${0}" ?disabled="${0}" ?readonly="${0}" clear-button-visible .checkValidity="${0}" .dataProvider="${0}" .selectedItem="${0}" .value="${0}" @change="${0}"> </vaadin-combo-box> `),a(null!==(e=this.itemValuePath)&&void 0!==e?e:void 0),a(null!==(t=this.itemLabelPath)&&void 0!==t?t:void 0),a(this._errorMessage),this.helperText,this.placeholder,this.label,this.allowCustomValue,this.disabled,this.readonly,this._checkValidity,this.__dataProvider,this.selectedItem,this._value,(e=>{e.stopPropagation();const t=e.currentTarget;this._value=t.value,this._value===t.value?(this.selectedItem=t.selectedItem,this.dispatchEvent(new CustomEvent("selected-item-changed"))):t.value=this._value}))}updated(e){if(super.updated(e),e.has("first")||e.has("itemLabelPath")){const e=this.renderRoot.querySelector("vaadin-combo-box");e&&(e.size=0,e.size=1)}}get _value(){var e;return null!==(e=super._value)&&void 0!==e?e:""}set _value(e){super._value=e}});
@@ -1,4 +1,4 @@
1
- import{_ as e}from"./shared-11014aad.js";import{E as t,T as n}from"./shared-4877ed05.js";import"./shared-205721a3.js";import{O as s}from"./shared-afefe2ac.js";import{T as i}from"./shared-6e977271.js";import"./shared-6a998243.js";import{h as r,P as o}from"./shared-48b76c74.js";import{L as a}from"./shared-724e9a20.js";import{C as l}from"./shared-61ade33e.js";import{I as A}from"./shared-d04dd602.js";import"./shared-0e5ea9cf.js";import{w as d,y as h,x as m}from"./shared-56addb06.js";import{a as c,F as u}from"./shared-7e201abd.js";import{c as p,L as g,h as v}from"./shared-dc73b9a5.js";import{D as b}from"./shared-6350f7d9.js";class y extends CustomEvent{constructor(e){super("change",{detail:e})}}class _ extends y{}const f=r`<dom-module id="lumo-list-box" theme-for="vaadin-list-box">
1
+ import{_ as e}from"./shared-11014aad.js";import{E as t,T as n}from"./shared-4877ed05.js";import"./shared-205721a3.js";import"./shared-bb08b5ce.js";import{T as s}from"./shared-6e977271.js";import"./shared-9a5da74d.js";import{h as i,P as r}from"./shared-48b76c74.js";import{L as o}from"./shared-724e9a20.js";import{C as a}from"./shared-61ade33e.js";import{I as l}from"./shared-cc723108.js";import"./shared-0e5ea9cf.js";import{w as A,y as d,x as h}from"./shared-56addb06.js";import{O as m}from"./shared-208e37af.js";import{a as c,F as u}from"./shared-7e201abd.js";import{c as p,L as g,h as v}from"./shared-dc73b9a5.js";import{D as b}from"./shared-5e35c5a5.js";class y extends CustomEvent{constructor(e){super("change",{detail:e})}}class _ extends y{}const f=i`<dom-module id="lumo-list-box" theme-for="vaadin-list-box">
2
2
  <template>
3
3
  <style>
4
4
  :host {
@@ -82,12 +82,12 @@ import{_ as e}from"./shared-11014aad.js";import{E as t,T as n}from"./shared-4877
82
82
  Copyright (c) 2019 Vaadin Ltd.
83
83
  This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
84
84
  */
85
- const x=e=>class extends(a(e)){static get properties(){return{multiple:{type:Boolean,value:!1,reflectToAttribute:!0,observer:"_multipleChanged"},selectedValues:{type:Array,notify:!0,value:function(){return[]}}}}static get observers(){return["_enhanceMultipleItems(items, multiple, selected, selectedValues, selectedValues.*)"]}ready(){this.addEventListener("click",(e=>this._onMultipleClick(e))),super.ready()}_enhanceMultipleItems(e,t,n,s){if(e&&t){if(s){const t=s.map((t=>e[t]));e.forEach((e=>e.selected=-1!==t.indexOf(e)))}this._scrollToLastSelectedItem()}}_scrollToLastSelectedItem(){const e=this.selectedValues.slice(-1)[0];e&&!e.disabled&&this._scrollToItem(e)}_onMultipleClick(e){const t=this._filterItems(e.composedPath())[0],n=t&&!t.disabled?this.items.indexOf(t):-1;n<0||!this.multiple||(e.preventDefault(),-1!==this.selectedValues.indexOf(n)?this.selectedValues=this.selectedValues.filter((e=>e!==n)):this.selectedValues=this.selectedValues.concat(n))}_multipleChanged(e,t){!e&&t&&(this.selectedValues=[],this.items.forEach((e=>e.selected=!1))),e&&!t&&void 0!==this.selected&&(this.push("selectedValues",this.selected),this.selected=void 0)}}
85
+ const x=e=>class extends(o(e)){static get properties(){return{multiple:{type:Boolean,value:!1,reflectToAttribute:!0,observer:"_multipleChanged"},selectedValues:{type:Array,notify:!0,value:function(){return[]}}}}static get observers(){return["_enhanceMultipleItems(items, multiple, selected, selectedValues, selectedValues.*)"]}ready(){this.addEventListener("click",(e=>this._onMultipleClick(e))),super.ready()}_enhanceMultipleItems(e,t,n,s){if(e&&t){if(s){const t=s.map((t=>e[t]));e.forEach((e=>e.selected=-1!==t.indexOf(e)))}this._scrollToLastSelectedItem()}}_scrollToLastSelectedItem(){const e=this.selectedValues.slice(-1)[0];e&&!e.disabled&&this._scrollToItem(e)}_onMultipleClick(e){const t=this._filterItems(e.composedPath())[0],n=t&&!t.disabled?this.items.indexOf(t):-1;n<0||!this.multiple||(e.preventDefault(),-1!==this.selectedValues.indexOf(n)?this.selectedValues=this.selectedValues.filter((e=>e!==n)):this.selectedValues=this.selectedValues.concat(n))}_multipleChanged(e,t){!e&&t&&(this.selectedValues=[],this.items.forEach((e=>e.selected=!1))),e&&!t&&void 0!==this.selected&&(this.push("selectedValues",this.selected),this.selected=void 0)}}
86
86
  /**
87
87
  @license
88
88
  Copyright (c) 2017 Vaadin Ltd.
89
89
  This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
90
- */;class w extends(t(x(n(o)))){static get template(){return r`
90
+ */;class w extends(t(x(n(r)))){static get template(){return i`
91
91
  <style>
92
92
  :host {
93
93
  display: flex;
@@ -107,7 +107,7 @@ This program is available under Apache License Version 2.0, available at https:/
107
107
  <div part="items">
108
108
  <slot></slot>
109
109
  </div>
110
- `}static get is(){return"vaadin-list-box"}static get version(){return"1.4.0"}static get properties(){return{orientation:{readOnly:!0}}}constructor(){super(),this.focused}ready(){super.ready(),this.setAttribute("role","list"),setTimeout(this._checkImport.bind(this),2e3)}get _scrollerElement(){return this.shadowRoot.querySelector('[part="items"]')}_checkImport(){var e=this.querySelector("vaadin-item");!e||e instanceof o||console.warn("Make sure you have imported the vaadin-item element.")}}customElements.define(w.is,w);const E=r`<dom-module id="lumo-select" theme-for="vaadin-select">
110
+ `}static get is(){return"vaadin-list-box"}static get version(){return"1.4.0"}static get properties(){return{orientation:{readOnly:!0}}}constructor(){super(),this.focused}ready(){super.ready(),this.setAttribute("role","list"),setTimeout(this._checkImport.bind(this),2e3)}get _scrollerElement(){return this.shadowRoot.querySelector('[part="items"]')}_checkImport(){var e=this.querySelector("vaadin-item");!e||e instanceof r||console.warn("Make sure you have imported the vaadin-item element.")}}customElements.define(w.is,w);const E=i`<dom-module id="lumo-select" theme-for="vaadin-select">
111
111
  <template>
112
112
  <style include="lumo-field-button">
113
113
  :host {
@@ -236,19 +236,19 @@ This program is available under Apache License Version 2.0, available at https:/
236
236
  Copyright (c) 2017 Vaadin Ltd.
237
237
  This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
238
238
  */
239
- const k=document.createElement("template");k.innerHTML='<dom-module id="vaadin-select-overlay-styles" theme-for="vaadin-select-overlay">\n <template>\n <style>\n :host {\n align-items: flex-start;\n justify-content: flex-start;\n }\n\n :host([bottom-aligned]) {\n justify-content: flex-end;\n }\n\n :host([right-aligned]) {\n align-items: flex-end;\n }\n\n :host([dir="rtl"]) {\n align-items: flex-end;\n }\n\n :host([dir="rtl"][right-aligned]) {\n align-items: flex-start;\n }\n </style>\n </template>\n</dom-module>',document.head.appendChild(k.content);class B extends s{static get is(){return"vaadin-select-overlay"}}
239
+ const k=document.createElement("template");k.innerHTML='<dom-module id="vaadin-select-overlay-styles" theme-for="vaadin-select-overlay">\n <template>\n <style>\n :host {\n align-items: flex-start;\n justify-content: flex-start;\n }\n\n :host([bottom-aligned]) {\n justify-content: flex-end;\n }\n\n :host([right-aligned]) {\n align-items: flex-end;\n }\n\n :host([dir="rtl"]) {\n align-items: flex-end;\n }\n\n :host([dir="rtl"][right-aligned]) {\n align-items: flex-start;\n }\n </style>\n </template>\n</dom-module>',document.head.appendChild(k.content);class B extends m{static get is(){return"vaadin-select-overlay"}}
240
240
  /**
241
241
  @license
242
242
  Copyright (c) 2017 Vaadin Ltd.
243
243
  This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
244
244
  */
245
- let C;customElements.define(B.is,B);class I extends i{static get is(){return"vaadin-select-text-field"}static get template(){if(super.template.content.querySelector('slot[name="input"]'))return super.template;if(!C){C=super.template.cloneNode(!0);const e=document.createElement("slot");e.setAttribute("name","value");const t=C.content.querySelector("input");t.parentElement.replaceChild(e,t),e.appendChild(t)}return C}get focusElement(){return this.shadowRoot.querySelector("[part=input-field]")}get inputElement(){return this.shadowRoot.querySelector("input")}}customElements.define(I.is,I);
245
+ let C;customElements.define(B.is,B);class I extends s{static get is(){return"vaadin-select-text-field"}static get template(){if(super.template.content.querySelector('slot[name="input"]'))return super.template;if(!C){C=super.template.cloneNode(!0);const e=document.createElement("slot");e.setAttribute("name","value");const t=C.content.querySelector("input");t.parentElement.replaceChild(e,t),e.appendChild(t)}return C}get focusElement(){return this.shadowRoot.querySelector("[part=input-field]")}get inputElement(){return this.shadowRoot.querySelector("input")}}customElements.define(I.is,I);
246
246
  /**
247
247
  @license
248
248
  Copyright (c) 2017 Vaadin Ltd.
249
249
  This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
250
250
  */
251
- const S=document.createElement("template");S.innerHTML="<custom-style>\n <style>\n @font-face {\n font-family: \"vaadin-select-icons\";\n src: url(data:application/font-woff;charset=utf-8;base64,d09GRgABAAAAAASEAAsAAAAABDgAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABPUy8yAAABCAAAAGAAAABgDxIGKmNtYXAAAAFoAAAAVAAAAFQXVtKHZ2FzcAAAAbwAAAAIAAAACAAAABBnbHlmAAABxAAAAHwAAAB8CohkJ2hlYWQAAAJAAAAANgAAADYOavgEaGhlYQAAAngAAAAkAAAAJAarA8ZobXR4AAACnAAAABQAAAAUCAABP2xvY2EAAAKwAAAADAAAAAwAKABSbWF4cAAAArwAAAAgAAAAIAAHABduYW1lAAAC3AAAAYYAAAGGmUoJ+3Bvc3QAAARkAAAAIAAAACAAAwAAAAMEAAGQAAUAAAKZAswAAACPApkCzAAAAesAMwEJAAAAAAAAAAAAAAAAAAAAARAAAAAAAAAAAAAAAAAAAAAAQAAA6QADwP/AAEADwABAAAAAAQAAAAAAAAAAAAAAIAAAAAAAAwAAAAMAAAAcAAEAAwAAABwAAwABAAAAHAAEADgAAAAKAAgAAgACAAEAIOkA//3//wAAAAAAIOkA//3//wAB/+MXBAADAAEAAAAAAAAAAAAAAAEAAf//AA8AAQAAAAAAAAAAAAIAADc5AQAAAAABAAAAAAAAAAAAAgAANzkBAAAAAAEAAAAAAAAAAAACAAA3OQEAAAAAAQE/AUAC6QIVABQAAAEwFx4BFxYxMDc+ATc2MTAjKgEjIgE/ISJPIiEhIk8iIUNCoEJDAhUhIk8iISEiTyIhAAEAAAABAABvL5bdXw889QALBAAAAAAA1jHaeQAAAADWMdp5AAAAAALpAhUAAAAIAAIAAAAAAAAAAQAAA8D/wAAABAAAAAAAAukAAQAAAAAAAAAAAAAAAAAAAAUEAAAAAAAAAAAAAAAAAAAABAABPwAAAAAACgAUAB4APgABAAAABQAVAAEAAAAAAAIAAAAAAAAAAAAAAAAAAAAAAAAADgCuAAEAAAAAAAEABwAAAAEAAAAAAAIABwBgAAEAAAAAAAMABwA2AAEAAAAAAAQABwB1AAEAAAAAAAUACwAVAAEAAAAAAAYABwBLAAEAAAAAAAoAGgCKAAMAAQQJAAEADgAHAAMAAQQJAAIADgBnAAMAAQQJAAMADgA9AAMAAQQJAAQADgB8AAMAAQQJAAUAFgAgAAMAAQQJAAYADgBSAAMAAQQJAAoANACkaWNvbW9vbgBpAGMAbwBtAG8AbwBuVmVyc2lvbiAxLjAAVgBlAHIAcwBpAG8AbgAgADEALgAwaWNvbW9vbgBpAGMAbwBtAG8AbwBuaWNvbW9vbgBpAGMAbwBtAG8AbwBuUmVndWxhcgBSAGUAZwB1AGwAYQByaWNvbW9vbgBpAGMAbwBtAG8AbwBuRm9udCBnZW5lcmF0ZWQgYnkgSWNvTW9vbi4ARgBvAG4AdAAgAGcAZQBuAGUAcgBhAHQAZQBkACAAYgB5ACAASQBjAG8ATQBvAG8AbgAuAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==) format('woff');\n font-weight: normal;\n font-style: normal;\n }\n </style>\n</custom-style>",document.head.appendChild(S.content);class T extends(t(l(n(c(A,o))))){static get template(){return r`
251
+ const S=document.createElement("template");S.innerHTML="<custom-style>\n <style>\n @font-face {\n font-family: \"vaadin-select-icons\";\n src: url(data:application/font-woff;charset=utf-8;base64,d09GRgABAAAAAASEAAsAAAAABDgAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABPUy8yAAABCAAAAGAAAABgDxIGKmNtYXAAAAFoAAAAVAAAAFQXVtKHZ2FzcAAAAbwAAAAIAAAACAAAABBnbHlmAAABxAAAAHwAAAB8CohkJ2hlYWQAAAJAAAAANgAAADYOavgEaGhlYQAAAngAAAAkAAAAJAarA8ZobXR4AAACnAAAABQAAAAUCAABP2xvY2EAAAKwAAAADAAAAAwAKABSbWF4cAAAArwAAAAgAAAAIAAHABduYW1lAAAC3AAAAYYAAAGGmUoJ+3Bvc3QAAARkAAAAIAAAACAAAwAAAAMEAAGQAAUAAAKZAswAAACPApkCzAAAAesAMwEJAAAAAAAAAAAAAAAAAAAAARAAAAAAAAAAAAAAAAAAAAAAQAAA6QADwP/AAEADwABAAAAAAQAAAAAAAAAAAAAAIAAAAAAAAwAAAAMAAAAcAAEAAwAAABwAAwABAAAAHAAEADgAAAAKAAgAAgACAAEAIOkA//3//wAAAAAAIOkA//3//wAB/+MXBAADAAEAAAAAAAAAAAAAAAEAAf//AA8AAQAAAAAAAAAAAAIAADc5AQAAAAABAAAAAAAAAAAAAgAANzkBAAAAAAEAAAAAAAAAAAACAAA3OQEAAAAAAQE/AUAC6QIVABQAAAEwFx4BFxYxMDc+ATc2MTAjKgEjIgE/ISJPIiEhIk8iIUNCoEJDAhUhIk8iISEiTyIhAAEAAAABAABvL5bdXw889QALBAAAAAAA1jHaeQAAAADWMdp5AAAAAALpAhUAAAAIAAIAAAAAAAAAAQAAA8D/wAAABAAAAAAAAukAAQAAAAAAAAAAAAAAAAAAAAUEAAAAAAAAAAAAAAAAAAAABAABPwAAAAAACgAUAB4APgABAAAABQAVAAEAAAAAAAIAAAAAAAAAAAAAAAAAAAAAAAAADgCuAAEAAAAAAAEABwAAAAEAAAAAAAIABwBgAAEAAAAAAAMABwA2AAEAAAAAAAQABwB1AAEAAAAAAAUACwAVAAEAAAAAAAYABwBLAAEAAAAAAAoAGgCKAAMAAQQJAAEADgAHAAMAAQQJAAIADgBnAAMAAQQJAAMADgA9AAMAAQQJAAQADgB8AAMAAQQJAAUAFgAgAAMAAQQJAAYADgBSAAMAAQQJAAoANACkaWNvbW9vbgBpAGMAbwBtAG8AbwBuVmVyc2lvbiAxLjAAVgBlAHIAcwBpAG8AbgAgADEALgAwaWNvbW9vbgBpAGMAbwBtAG8AbwBuaWNvbW9vbgBpAGMAbwBtAG8AbwBuUmVndWxhcgBSAGUAZwB1AGwAYQByaWNvbW9vbgBpAGMAbwBtAG8AbwBuRm9udCBnZW5lcmF0ZWQgYnkgSWNvTW9vbi4ARgBvAG4AdAAgAGcAZQBuAGUAcgBhAHQAZQBkACAAYgB5ACAASQBjAG8ATQBvAG8AbgAuAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==) format('woff');\n font-weight: normal;\n font-style: normal;\n }\n </style>\n</custom-style>",document.head.appendChild(S.content);class T extends(t(a(n(c(l,r))))){static get template(){return i`
252
252
  <style>
253
253
  :host {
254
254
  display: inline-block;
@@ -281,7 +281,7 @@ const S=document.createElement("template");S.innerHTML="<custom-style>\n <style
281
281
  <vaadin-select-overlay opened="{{opened}}" with-backdrop="[[_phone]]" phone\$="[[_phone]]" theme\$="[[theme]]"></vaadin-select-overlay>
282
282
 
283
283
  <iron-media-query query="[[_phoneMediaQuery]]" query-matches="{{_phone}}"></iron-media-query>
284
- `}static get is(){return"vaadin-select"}static get version(){return"2.5.0"}static get properties(){return{opened:{type:Boolean,value:!1,notify:!0,reflectToAttribute:!0,observer:"_openedChanged"},renderer:Function,errorMessage:{type:String,value:""},label:{type:String},value:{type:String,value:"",notify:!0,observer:"_valueChanged"},required:{type:Boolean,reflectToAttribute:!0,observer:"_requiredChanged"},invalid:{type:Boolean,reflectToAttribute:!0,notify:!0,value:!1},name:{type:String,reflectToAttribute:!0},placeholder:{type:String},helperText:{type:String,value:""},readonly:{type:Boolean,value:!1,reflectToAttribute:!0},_phone:Boolean,_phoneMediaQuery:{value:"(max-width: 420px), (max-height: 420px)"},_overlayElement:Object,_inputElement:Object,_toggleElement:Object,_items:Object,_contentTemplate:Object,_oldTemplate:Object,_oldRenderer:Object}}static get observers(){return["_updateSelectedItem(value, _items)","_updateAriaExpanded(opened, _toggleElement, _inputElement)","_templateOrRendererChanged(_contentTemplate, renderer, _overlayElement)"]}constructor(){super(),this._boundSetPosition=this._setPosition.bind(this)}connectedCallback(){super.connectedCallback(),this.addEventListener("iron-resize",this._boundSetPosition)}ready(){super.ready(),this._overlayElement=this.shadowRoot.querySelector("vaadin-select-overlay"),this._valueElement=this.shadowRoot.querySelector('[part="value"]'),this._toggleElement=this.shadowRoot.querySelector('[part="toggle-button"]'),this._nativeInput=this.focusElement.shadowRoot.querySelector("input"),this._nativeInput.setAttribute("aria-hidden",!0),this._nativeInput.setAttribute("tabindex",-1),this._nativeInput.style.pointerEvents="none",this.focusElement.addEventListener("click",(e=>{const t=Array.from(e.composedPath()).some((e=>e.nodeType===Node.ELEMENT_NODE&&"helper"===e.getAttribute("slot")));this.opened=!this.readonly&&!t})),this.focusElement.addEventListener("keydown",(e=>this._onKeyDown(e))),this._observer=new u(this,(e=>this._setTemplateFromNodes(e.addedNodes))),this._observer.flush()}_setTemplateFromNodes(e){const t=Array.from(e).filter((e=>e.localName&&"template"===e.localName))[0]||this._contentTemplate;this._overlayElement.template=this._contentTemplate=t,this._setForwardHostProps()}_setForwardHostProps(){if(this._overlayElement.content){const e=this._overlayElement._instance&&this._overlayElement._instance.forwardHostProp;this._overlayElement._instance&&(this._overlayElement._instance.forwardHostProp=(...t)=>{e.apply(this._overlayElement._instance,t),setTimeout((()=>{this._updateValueSlot()}))},this._assignMenuElement())}}render(){this._overlayElement&&(this._overlayElement.render(),this._menuElement&&this._menuElement.items&&this._updateSelectedItem(this.value,this._menuElement.items))}_removeNewRendererOrTemplate(e,t,n,s){e!==t?this._contentTemplate=void 0:n!==s&&(this.renderer=void 0)}_templateOrRendererChanged(e,t,n){if(n){if(e&&t)throw this._removeNewRendererOrTemplate(e,this._oldTemplate,t,this._oldRenderer),new Error("You should only use either a renderer or a template for select content");this._oldTemplate=e,this._oldRenderer=t,t&&(n.setProperties({owner:this,renderer:t}),this.render(),n.content.firstChild&&this._assignMenuElement())}}_assignMenuElement(){this._menuElement=Array.from(this._overlayElement.content.children).filter((e=>"style"!==e.localName))[0],this._menuElement&&(this._menuElement.addEventListener("items-changed",(e=>{this._items=this._menuElement.items,this._items.forEach((e=>e.setAttribute("role","option")))})),this._menuElement.addEventListener("selected-changed",(e=>this._updateValueSlot())),this._menuElement.addEventListener("keydown",(e=>this._onKeyDownInside(e))),this._menuElement.addEventListener("click",(e=>{this.__userInteraction=!0,this.opened=!1}),!0),this._menuElement.setAttribute("role","listbox"))}get focusElement(){return this._inputElement||(this._inputElement=this.shadowRoot.querySelector("vaadin-select-text-field"))}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("iron-resize",this._boundSetPosition),this.opened=!1}notifyResize(){super.notifyResize(),this.positionTarget&&this.opened&&(this._setPosition(),requestAnimationFrame(this._setPosition.bind(this)))}_requiredChanged(e){this.setAttribute("aria-required",e)}_valueChanged(e,t){""===e?this.focusElement.removeAttribute("has-value"):this.focusElement.setAttribute("has-value",""),""===e&&void 0===t||this.validate()}_onKeyDown(e){if(!this.readonly&&!this.opened)if(/^(Enter|SpaceBar|\s|ArrowDown|Down|ArrowUp|Up)$/.test(e.key))e.preventDefault(),this.opened=!0;else if(/[a-zA-Z0-9]/.test(e.key)&&1===e.key.length){const t=this._menuElement.selected,n=void 0!==t?t:-1,s=this._menuElement._searchKey(n,e.key);s>=0&&(this.__userInteraction=!0,this._updateSelectedItem(this._items[s].value,this._items))}}_onKeyDownInside(e){/^(Tab)$/.test(e.key)&&(this.opened=!1)}_openedChanged(e,t){if(e){if(!this._overlayElement||!this._menuElement||!this._toggleElement||!this.focusElement||this.disabled||this.readonly)return void(this.opened=!1);this._openedWithFocusRing=this.hasAttribute("focus-ring")||this.focusElement.hasAttribute("focus-ring"),this._menuElement.focus(),this._setPosition(),window.addEventListener("scroll",this._boundSetPosition,!0)}else t&&(this.focusElement.focus(),this._openedWithFocusRing&&this.focusElement.setAttribute("focus-ring",""),this.validate(),window.removeEventListener("scroll",this._boundSetPosition,!0))}_hasContent(e){return!!e&&Boolean(e.hasAttribute("label")?e.getAttribute("label"):e.textContent.trim()||e.children.length)}_attachSelectedItem(e){if(!e)return;let t;e.hasAttribute("label")?(t=document.createElement("vaadin-item"),t.textContent=e.getAttribute("label")):t=e.cloneNode(!0),t._sourceItem=e,t.removeAttribute("tabindex"),t.removeAttribute("role"),this._valueElement.appendChild(t),t.selected=!0}_updateAriaExpanded(e,t,n){t&&t.setAttribute("aria-expanded",e),n&&n.focusElement&&n.focusElement.setAttribute("aria-expanded",e)}_updateValueSlot(){this.opened=!1,this._valueElement.innerHTML="";const e=this._items[this._menuElement.selected],t=this._hasContent(e),n=this._inputElement.shadowRoot.querySelector('slot[name="input"]')?"input":"value";this._valueElement.slot=t?n:"",t&&window.ShadyDOM&&window.ShadyDOM.flush(),this._attachSelectedItem(e),!this._valueChanging&&e&&(this._selectedChanging=!0,this.value=e.value||"",this.__userInteraction&&(this.dispatchEvent(new CustomEvent("change",{bubbles:!0})),this.__userInteraction=!1),delete this._selectedChanging)}_updateSelectedItem(e,t){t&&(this._menuElement.selected=t.reduce(((t,n,s)=>void 0===t&&n.value===e?s:t),void 0),this._selectedChanging||(this._valueChanging=!0,this._updateValueSlot(),delete this._valueChanging))}_setFocused(e){super._setFocused(this.opened||e),this.focusElement._setFocused(this.hasAttribute("focused")),!this.hasAttribute("focused")&&this.validate()}_setPosition(){const e=this._inputElement.shadowRoot.querySelector('[part~="input-field"]').getBoundingClientRect(),t=Math.min(window.innerWidth,document.documentElement.clientWidth),n=Math.min(window.innerHeight,document.documentElement.clientHeight),s=this.__shouldAlignRight(e,t),i=this.__shouldAlignBottom(e,n);s?(this._overlayElement.setAttribute("right-aligned",""),this._overlayElement.style.right=t-e.right+"px",this._overlayElement.style.removeProperty("left")):(this._overlayElement.removeAttribute("right-aligned"),this._overlayElement.style.left=e.left+"px",this._overlayElement.style.removeProperty("right")),i?(this._overlayElement.setAttribute("bottom-aligned",""),this._overlayElement.style.removeProperty("top"),this._overlayElement.style.bottom=n-e.bottom+"px"):(this._overlayElement.removeAttribute("bottom-aligned"),this._overlayElement.style.removeProperty("bottom"),this._overlayElement.style.top=e.top+"px"),this._overlayElement.updateStyles({"--vaadin-select-text-field-width":e.width+"px"})}__shouldAlignRight(e,t){const n="rtl"===this.getAttribute("dir"),s=e.left/t,i=(t-e.right)/t;return n?s>.3:i<.3}__shouldAlignBottom(e,t){return e.top>(t-e.height)/2}_setInvalid(e){this._shouldSetInvalid(e)&&(this.invalid=e)}_shouldSetInvalid(e){return!0}validate(){const e=!(!this.disabled&&this.required&&!this.value);return this._setInvalid(!e),this.dispatchEvent(new CustomEvent("validated",{detail:{valid:e}})),e}}customElements.define(T.is,T);let Q,D,M=e=>e;d("vaadin-list-box",p(Q||(Q=M`
284
+ `}static get is(){return"vaadin-select"}static get version(){return"2.5.0"}static get properties(){return{opened:{type:Boolean,value:!1,notify:!0,reflectToAttribute:!0,observer:"_openedChanged"},renderer:Function,errorMessage:{type:String,value:""},label:{type:String},value:{type:String,value:"",notify:!0,observer:"_valueChanged"},required:{type:Boolean,reflectToAttribute:!0,observer:"_requiredChanged"},invalid:{type:Boolean,reflectToAttribute:!0,notify:!0,value:!1},name:{type:String,reflectToAttribute:!0},placeholder:{type:String},helperText:{type:String,value:""},readonly:{type:Boolean,value:!1,reflectToAttribute:!0},_phone:Boolean,_phoneMediaQuery:{value:"(max-width: 420px), (max-height: 420px)"},_overlayElement:Object,_inputElement:Object,_toggleElement:Object,_items:Object,_contentTemplate:Object,_oldTemplate:Object,_oldRenderer:Object}}static get observers(){return["_updateSelectedItem(value, _items)","_updateAriaExpanded(opened, _toggleElement, _inputElement)","_templateOrRendererChanged(_contentTemplate, renderer, _overlayElement)"]}constructor(){super(),this._boundSetPosition=this._setPosition.bind(this)}connectedCallback(){super.connectedCallback(),this.addEventListener("iron-resize",this._boundSetPosition)}ready(){super.ready(),this._overlayElement=this.shadowRoot.querySelector("vaadin-select-overlay"),this._valueElement=this.shadowRoot.querySelector('[part="value"]'),this._toggleElement=this.shadowRoot.querySelector('[part="toggle-button"]'),this._nativeInput=this.focusElement.shadowRoot.querySelector("input"),this._nativeInput.setAttribute("aria-hidden",!0),this._nativeInput.setAttribute("tabindex",-1),this._nativeInput.style.pointerEvents="none",this.focusElement.addEventListener("click",(e=>{const t=Array.from(e.composedPath()).some((e=>e.nodeType===Node.ELEMENT_NODE&&"helper"===e.getAttribute("slot")));this.opened=!this.readonly&&!t})),this.focusElement.addEventListener("keydown",(e=>this._onKeyDown(e))),this._observer=new u(this,(e=>this._setTemplateFromNodes(e.addedNodes))),this._observer.flush()}_setTemplateFromNodes(e){const t=Array.from(e).filter((e=>e.localName&&"template"===e.localName))[0]||this._contentTemplate;this._overlayElement.template=this._contentTemplate=t,this._setForwardHostProps()}_setForwardHostProps(){if(this._overlayElement.content){const e=this._overlayElement._instance&&this._overlayElement._instance.forwardHostProp;this._overlayElement._instance&&(this._overlayElement._instance.forwardHostProp=(...t)=>{e.apply(this._overlayElement._instance,t),setTimeout((()=>{this._updateValueSlot()}))},this._assignMenuElement())}}render(){this._overlayElement&&(this._overlayElement.render(),this._menuElement&&this._menuElement.items&&this._updateSelectedItem(this.value,this._menuElement.items))}_removeNewRendererOrTemplate(e,t,n,s){e!==t?this._contentTemplate=void 0:n!==s&&(this.renderer=void 0)}_templateOrRendererChanged(e,t,n){if(n){if(e&&t)throw this._removeNewRendererOrTemplate(e,this._oldTemplate,t,this._oldRenderer),new Error("You should only use either a renderer or a template for select content");this._oldTemplate=e,this._oldRenderer=t,t&&(n.setProperties({owner:this,renderer:t}),this.render(),n.content.firstChild&&this._assignMenuElement())}}_assignMenuElement(){this._menuElement=Array.from(this._overlayElement.content.children).filter((e=>"style"!==e.localName))[0],this._menuElement&&(this._menuElement.addEventListener("items-changed",(e=>{this._items=this._menuElement.items,this._items.forEach((e=>e.setAttribute("role","option")))})),this._menuElement.addEventListener("selected-changed",(e=>this._updateValueSlot())),this._menuElement.addEventListener("keydown",(e=>this._onKeyDownInside(e))),this._menuElement.addEventListener("click",(e=>{this.__userInteraction=!0,this.opened=!1}),!0),this._menuElement.setAttribute("role","listbox"))}get focusElement(){return this._inputElement||(this._inputElement=this.shadowRoot.querySelector("vaadin-select-text-field"))}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("iron-resize",this._boundSetPosition),this.opened=!1}notifyResize(){super.notifyResize(),this.positionTarget&&this.opened&&(this._setPosition(),requestAnimationFrame(this._setPosition.bind(this)))}_requiredChanged(e){this.setAttribute("aria-required",e)}_valueChanged(e,t){""===e?this.focusElement.removeAttribute("has-value"):this.focusElement.setAttribute("has-value",""),""===e&&void 0===t||this.validate()}_onKeyDown(e){if(!this.readonly&&!this.opened)if(/^(Enter|SpaceBar|\s|ArrowDown|Down|ArrowUp|Up)$/.test(e.key))e.preventDefault(),this.opened=!0;else if(/[a-zA-Z0-9]/.test(e.key)&&1===e.key.length){const t=this._menuElement.selected,n=void 0!==t?t:-1,s=this._menuElement._searchKey(n,e.key);s>=0&&(this.__userInteraction=!0,this._updateSelectedItem(this._items[s].value,this._items))}}_onKeyDownInside(e){/^(Tab)$/.test(e.key)&&(this.opened=!1)}_openedChanged(e,t){if(e){if(!this._overlayElement||!this._menuElement||!this._toggleElement||!this.focusElement||this.disabled||this.readonly)return void(this.opened=!1);this._openedWithFocusRing=this.hasAttribute("focus-ring")||this.focusElement.hasAttribute("focus-ring"),this._menuElement.focus(),this._setPosition(),window.addEventListener("scroll",this._boundSetPosition,!0)}else t&&(this.focusElement.focus(),this._openedWithFocusRing&&this.focusElement.setAttribute("focus-ring",""),this.validate(),window.removeEventListener("scroll",this._boundSetPosition,!0))}_hasContent(e){return!!e&&Boolean(e.hasAttribute("label")?e.getAttribute("label"):e.textContent.trim()||e.children.length)}_attachSelectedItem(e){if(!e)return;let t;e.hasAttribute("label")?(t=document.createElement("vaadin-item"),t.textContent=e.getAttribute("label")):t=e.cloneNode(!0),t._sourceItem=e,t.removeAttribute("tabindex"),t.removeAttribute("role"),this._valueElement.appendChild(t),t.selected=!0}_updateAriaExpanded(e,t,n){t&&t.setAttribute("aria-expanded",e),n&&n.focusElement&&n.focusElement.setAttribute("aria-expanded",e)}_updateValueSlot(){this.opened=!1,this._valueElement.innerHTML="";const e=this._items[this._menuElement.selected],t=this._hasContent(e),n=this._inputElement.shadowRoot.querySelector('slot[name="input"]')?"input":"value";this._valueElement.slot=t?n:"",t&&window.ShadyDOM&&window.ShadyDOM.flush(),this._attachSelectedItem(e),!this._valueChanging&&e&&(this._selectedChanging=!0,this.value=e.value||"",this.__userInteraction&&(this.dispatchEvent(new CustomEvent("change",{bubbles:!0})),this.__userInteraction=!1),delete this._selectedChanging)}_updateSelectedItem(e,t){t&&(this._menuElement.selected=t.reduce(((t,n,s)=>void 0===t&&n.value===e?s:t),void 0),this._selectedChanging||(this._valueChanging=!0,this._updateValueSlot(),delete this._valueChanging))}_setFocused(e){super._setFocused(this.opened||e),this.focusElement._setFocused(this.hasAttribute("focused")),!this.hasAttribute("focused")&&this.validate()}_setPosition(){const e=this._inputElement.shadowRoot.querySelector('[part~="input-field"]').getBoundingClientRect(),t=Math.min(window.innerWidth,document.documentElement.clientWidth),n=Math.min(window.innerHeight,document.documentElement.clientHeight),s=this.__shouldAlignRight(e,t),i=this.__shouldAlignBottom(e,n);s?(this._overlayElement.setAttribute("right-aligned",""),this._overlayElement.style.right=t-e.right+"px",this._overlayElement.style.removeProperty("left")):(this._overlayElement.removeAttribute("right-aligned"),this._overlayElement.style.left=e.left+"px",this._overlayElement.style.removeProperty("right")),i?(this._overlayElement.setAttribute("bottom-aligned",""),this._overlayElement.style.removeProperty("top"),this._overlayElement.style.bottom=n-e.bottom+"px"):(this._overlayElement.removeAttribute("bottom-aligned"),this._overlayElement.style.removeProperty("bottom"),this._overlayElement.style.top=e.top+"px"),this._overlayElement.updateStyles({"--vaadin-select-text-field-width":e.width+"px"})}__shouldAlignRight(e,t){const n="rtl"===this.getAttribute("dir"),s=e.left/t,i=(t-e.right)/t;return n?s>.3:i<.3}__shouldAlignBottom(e,t){return e.top>(t-e.height)/2}_setInvalid(e){this._shouldSetInvalid(e)&&(this.invalid=e)}_shouldSetInvalid(e){return!0}validate(){const e=!(!this.disabled&&this.required&&!this.value);return this._setInvalid(!e),this.dispatchEvent(new CustomEvent("validated",{detail:{valid:e}})),e}}customElements.define(T.is,T);let Q,D,M=e=>e;A("vaadin-list-box",p(Q||(Q=M`
285
285
  [part='items'] ::slotted(vaadin-item.dropdown-divisor){
286
286
  color:var(--lumo-contrast-40pct);
287
287
  box-shadow:0 1px var(--lumo-contrast-10pct);
@@ -291,4 +291,4 @@ const S=document.createElement("template");S.innerHTML="<custom-style>\n <style
291
291
  [part='items'] ::slotted(vaadin-item.dropdown-sub-item){
292
292
  margin-left:var(--lumo-space-l);
293
293
  }
294
- `)));class L extends g{constructor(){super(),this.disabled=!1,this.label="",this.value=null,this.items=null,this.getText=e=>e,this.__unexistentValue=`@foxy.io/elements#dropdown-${Math.random().toFixed(16).substr(2)}`,this.__renderedItems={},this.__list=document.createElement("vaadin-list-box")}static get properties(){return e(e({},super.properties),{},{disabled:{type:Boolean},getText:{type:Object,attribute:!1},items:{type:Array},label:{type:String},value:{type:String}})}static get styles(){return h.styles}render(){return v(D||(D=M` <vaadin-select class="w-full ${0}" data-testid="select" .label="${0}" .value="${0}" .disabled="${0}" .renderer="${0}" @change="${0}"> </vaadin-select> `),this.label?"-mt-m":"",this.label,null===this.value?this.__unexistentValue:this.value,this.disabled,this.__renderItems.bind(this),this.__handleChange)}__renderItems(e){var t;let n=e.querySelector("vaadin-list-box");null===n&&(e.appendChild(this.__list),n=this.__list);for(const e of Object.values(this.__renderedItems))e.dataset.keep="";const s=null!==(t=this.items)&&void 0!==t?t:[];for(let e=0;e<s.length;++e)if("string"==typeof s[e])this.__addOrKeepItem(s[e],s[e],n).classList.add("dropdown-item");else if(Array.isArray(s[e])){const t=this.__addOrKeepItem(s[e][0],s[e][0],n);t.classList.add("dropdown-item","dropdown-divisor"),t.disabled=!0;for(const t of s[e][1])this.__addOrKeepItem(s[e][0]+": "+t,t,n).classList.add("dropdown-sub-item")}for(const e of Object.values(this.__renderedItems)){const t=e;t.dataset.keep||(e.remove(),delete this.__renderedItems[t.dataset.trackId])}}__addOrKeepItem(e,t,n){let s;return this.__renderedItems[e]?s=this.__renderedItems[e]:(s=document.createElement("vaadin-item"),this.__renderedItems[e]=s,s.value=e,n.appendChild(s)),s.dataset.keep="true",s.dataset.trackId=e,s.textContent=this.getText(t),s}__handleChange(e){const t=e.target.value,n=t===this.__unexistentValue?null:t;this.dispatchEvent(new b(n))}}let R,j,$=e=>e;class O extends g{constructor(){super(...arguments),this.variant=null}static get styles(){return[h.styles,p(R||(R=$`@keyframes blink{from{opacity:.5}to{opacity:1}}.animated{animation:blink .5s infinite alternate}:host{display:inline-block;min-width:4rem}`))]}static get properties(){return e(e({},super.properties),{},{variant:{type:String}})}render(){const e="error"===this.variant?"bg-error-10":"bg-contrast-10",t=null===this.variant?"animated":"";return v(j||(j=$` <div class="relative"> <span class="opacity-0"><slot></slot></span> <div class="${0} ${0} rounded my-xs absolute inset-0"></div> </div> `),e,t)}}let P,V,q,G=e=>e;class N extends m{constructor(){super(...arguments),this.key=""}static get scopedElements(){return{"x-skeleton":O}}static get properties(){return e(e({},super.properties),{},{key:{type:String,reflect:!0},opts:{type:Object}})}static get styles(){return[super.styles,p(P||(P=G`:host{display:inline-block;color:inherit;line-height:inherit;font:inherit}`))]}get whenReady(){return this._whenI18nReady.then((()=>this.updateComplete))}render(){return this._isI18nReady?v(V||(V=G`${0}<slot></slot>`),this._t(this.key,this.opts)):v(q||(q=G`<x-skeleton class="block">${0}<slot></slot></x-skeleton>`),this.key)}}function W(...e){return e.filter((e=>!!e))}let F,H,z,K,U=e=>e;class Y extends m{constructor(){super(...arguments),this.disabled=!1,this.value=[]}static get scopedElements(){return{"x-i18n":N}}static get properties(){return e(e({},super.properties),{},{disabled:{type:Boolean},value:{type:Array}})}render(){const e=Y._allDays.map((e=>{try{return e.toLocaleString(this.lang,{minimumIntegerDigits:2})}catch(t){return e.toString()}}));return v(F||(F=U` <div class="space-y-s"> <div class="flex flex-wrap -mx-xs -mb-xs" style="max-width:364px;font-feature-settings:'tnum' 1"> ${0} </div> ${0} </div> `),Y._allDays.map(((t,n)=>v(H||(H=U` <label class="${0}"> ${0} <input type="checkbox" class="sr-only" ?disabled="${0}" ?checked="${0}" @change="${0}"> </label> `),this._getLabelClass(t),e[n],this.disabled,this.value.includes(t),(e=>this._handleChange(e,t))))),W(this.value.length>0&&v(z||(z=U` <p class="text-s text-tertiary leading-s"> <x-i18n key="monthday-picker.hint" .opts="${0}" .lang="${0}"> </x-i18n> ${0} </p> `),{days:this.value},this.lang,W([29,30,31].some((e=>this.value.includes(e)))&&v(K||(K=U`<x-i18n key="monthday-picker.warning" .lang="${0}"></x-i18n>`),this.lang)))))}_getLabelClass(e){let t="flex items-center justify-center m-xs p-s rounded text-m font-medium transition duration-200 sm-p-0 sm-h-m sm-w-l ";return this.value.includes(e)||(t+="bg-contrast-5 "),this._isI18nReady&&!this.disabled?(t+="cursor-pointer ",t+=this.value.includes(e)?"text-base ":"hover-bg-primary-10 ",e<29?(t+="focus-within-shadow-outline ",t+=this.value.includes(e)?"bg-primary":"text-body"):(t+="focus-within-shadow-outline-error ",t+=this.value.includes(e)?"bg-error":"text-error")):(t+="text-transparent ",this.value.includes(e)&&(t+=e<29?"bg-primary-50":"bg-error-10")),t}_handleChange(e,t){e.stopPropagation(),this._toggle(t),this._sendChange()}_sendChange(){this.dispatchEvent(new y(this.value))}_toggle(e){const t=this.value.indexOf(e);this.value=-1===t?[...this.value,e]:this.value.filter(((e,n)=>n!==t))}}Y._allDays=Array.from(new Array(31),((e,t)=>t+1));const J=document.createElement("template");function Z(e,t,n="long"){const s=new Date;for(;s.getDay()!==e;)s.setDate(s.getDate()+1);return s.toLocaleDateString(t,{weekday:n})}J.innerHTML='<dom-module id="lumo-badge">\n <template>\n <style>\n [theme~="badge"] {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n padding: 0.4em calc(0.5em + var(--lumo-border-radius-s) / 4);\n color: var(--lumo-primary-text-color);\n background-color: var(--lumo-primary-color-10pct);\n border-radius: var(--lumo-border-radius-s);\n font-family: var(--lumo-font-family);\n font-size: var(--lumo-font-size-s);\n line-height: 1;\n font-weight: 500;\n text-transform: initial;\n letter-spacing: initial;\n min-width: calc(var(--lumo-line-height-xs) * 1em + 0.45em);\n }\n\n /* Ensure proper vertical alignment */\n [theme~="badge"]::before {\n display: inline-block;\n content: "\\2003";\n width: 0;\n }\n\n [theme~="badge"][theme~="small"] {\n font-size: var(--lumo-font-size-xxs);\n line-height: 1;\n }\n\n /* Colors */\n\n [theme~="badge"][theme~="success"] {\n color: var(--lumo-success-text-color);\n background-color: var(--lumo-success-color-10pct);\n }\n\n [theme~="badge"][theme~="error"] {\n color: var(--lumo-error-text-color);\n background-color: var(--lumo-error-color-10pct);\n }\n\n [theme~="badge"][theme~="contrast"] {\n color: var(--lumo-contrast-80pct);\n background-color: var(--lumo-contrast-5pct);\n }\n\n /* Primary */\n\n [theme~="badge"][theme~="primary"] {\n color: var(--lumo-primary-contrast-color);\n background-color: var(--lumo-primary-color);\n }\n\n [theme~="badge"][theme~="success"][theme~="primary"] {\n color: var(--lumo-success-contrast-color);\n background-color: var(--lumo-success-color);\n }\n\n [theme~="badge"][theme~="error"][theme~="primary"] {\n color: var(--lumo-error-contrast-color);\n background-color: var(--lumo-error-color);\n }\n\n [theme~="badge"][theme~="contrast"][theme~="primary"] {\n color: var(--lumo-base-color);\n background-color: var(--lumo-contrast);\n }\n\n /* Links */\n\n [theme~="badge"][href]:hover {\n text-decoration: none;\n }\n\n /* Icon */\n\n [theme~="badge"] iron-icon {\n margin: -0.25em 0;\n --iron-icon-width: 1.5em;\n --iron-icon-height: 1.5em;\n }\n\n [theme~="badge"] iron-icon:first-child {\n margin-left: -0.375em;\n }\n\n [theme~="badge"] iron-icon:last-child {\n margin-right: -0.375em;\n }\n\n [theme~="badge"][icon] {\n min-width: 0;\n padding: 0;\n font-size: 1rem;\n --iron-icon-width: var(--lumo-icon-size-m);\n --iron-icon-height: var(--lumo-icon-size-m);\n }\n\n [theme~="badge"][icon][theme~="small"] {\n --iron-icon-width: var(--lumo-icon-size-s);\n --iron-icon-height: var(--lumo-icon-size-s);\n }\n\n /* Empty */\n\n [theme~="badge"]:not([icon]):empty {\n min-width: 0;\n width: 1em;\n height: 1em;\n padding: 0;\n border-radius: 50%;\n background-color: var(--lumo-primary-color);\n }\n\n [theme~="badge"][theme~="small"]:not([icon]):empty {\n width: 0.75em;\n height: 0.75em;\n }\n\n [theme~="badge"][theme~="contrast"]:not([icon]):empty {\n background-color: var(--lumo-contrast);\n }\n\n [theme~="badge"][theme~="success"]:not([icon]):empty {\n background-color: var(--lumo-success-color);\n }\n\n [theme~="badge"][theme~="error"]:not([icon]):empty {\n background-color: var(--lumo-error-color);\n }\n\n /* Pill */\n\n [theme~="badge"][theme~="pill"] {\n --lumo-border-radius-s: 1em;\n }\n\n /* RTL specific styles */\n\n [dir="rtl"][theme~="badge"] iron-icon:first-child {\n margin-right: -0.375em;\n margin-left: 0;\n }\n\n [dir="rtl"][theme~="badge"] iron-icon:last-child {\n margin-left: -0.375em;\n margin-right: 0;\n }\n </style>\n </template>\n</dom-module>',document.head.appendChild(J.content);let X,ee,te,ne=e=>e;class se extends Y{render(){return v(X||(X=ne` <div class="space-y-s"> <div class="flex flex-wrap -mx-xs -mb-xs text-m uppercase"> ${0} </div> ${0} </div> `),se._allDays.map((e=>v(ee||(ee=ne` <label class="${0}"> ${0} <input type="checkbox" class="sr-only" ?disabled="${0}" ?checked="${0}" @change="${0}"> </label> `),this._getLabelClass(e),Z(e,this.lang,"short"),this.disabled||!this._isI18nReady,this.value.includes(e),(t=>this._handleChange(t,e))))),W(this.value.length>0&&v(te||(te=ne` <p class="text-s text-tertiary leading-s"> <x-i18n key="weekday-picker.hint" .lang="${0}" .opts="${0}"> </x-i18n> </p> `),this.lang,{days:this.value})))}_getLabelClass(e){let t="flex items-center justify-center m-xs h-m w-xl rounded font-medium transition duration-200 ";return this._isI18nReady&&!this.disabled?(t+="cursor-pointer focus-within-shadow-outline ",t+=this.value.includes(e)?"text-base bg-primary":"bg-contrast-5 hover-bg-contrast-10 text-body"):(t+="text-transparent ",t+=this.value.includes(e)?"bg-primary-50":"bg-contrast-5"),t}_sendChange(){this.dispatchEvent(new _(this.value))}}se._allDays=new Array(7).fill(0).map(((e,t)=>t));export{L as D,N as I,Y as M,O as S,se as W,T as a,W as c,Z as t};
294
+ `)));class j extends g{constructor(){super(),this.disabled=!1,this.label="",this.value=null,this.items=null,this.getText=e=>e,this.__unexistentValue=`@foxy.io/elements#dropdown-${Math.random().toFixed(16).substr(2)}`,this.__renderedItems={},this.__list=document.createElement("vaadin-list-box")}static get properties(){return e(e({},super.properties),{},{disabled:{type:Boolean},getText:{type:Object,attribute:!1},items:{type:Array},label:{type:String},value:{type:String}})}static get styles(){return d.styles}render(){return v(D||(D=M` <vaadin-select class="w-full ${0}" data-testid="select" .label="${0}" .value="${0}" .disabled="${0}" .renderer="${0}" @change="${0}"> </vaadin-select> `),this.label?"-mt-m":"",this.label,null===this.value?this.__unexistentValue:this.value,this.disabled,this.__renderItems.bind(this),this.__handleChange)}__renderItems(e){var t;let n=e.querySelector("vaadin-list-box");null===n&&(e.appendChild(this.__list),n=this.__list);for(const e of Object.values(this.__renderedItems))e.dataset.keep="";const s=null!==(t=this.items)&&void 0!==t?t:[];for(let e=0;e<s.length;++e)if("string"==typeof s[e])this.__addOrKeepItem(s[e],s[e],n).classList.add("dropdown-item");else if(Array.isArray(s[e])){const t=this.__addOrKeepItem(s[e][0],s[e][0],n);t.classList.add("dropdown-item","dropdown-divisor"),t.disabled=!0;for(const t of s[e][1])this.__addOrKeepItem(s[e][0]+": "+t,t,n).classList.add("dropdown-sub-item")}for(const e of Object.values(this.__renderedItems)){const t=e;t.dataset.keep||(e.remove(),delete this.__renderedItems[t.dataset.trackId])}}__addOrKeepItem(e,t,n){let s;return this.__renderedItems[e]?s=this.__renderedItems[e]:(s=document.createElement("vaadin-item"),this.__renderedItems[e]=s,s.value=e,n.appendChild(s)),s.dataset.keep="true",s.dataset.trackId=e,s.textContent=this.getText(t),s}__handleChange(e){const t=e.target.value,n=t===this.__unexistentValue?null:t;this.dispatchEvent(new b(n))}}let L,R,$=e=>e;class O extends g{constructor(){super(...arguments),this.variant=null}static get styles(){return[d.styles,p(L||(L=$`@keyframes blink{from{opacity:.5}to{opacity:1}}.animated{animation:blink .5s infinite alternate}:host{display:inline-block;min-width:4rem}`))]}static get properties(){return e(e({},super.properties),{},{variant:{type:String}})}render(){const e="error"===this.variant?"bg-error-10":"bg-contrast-10",t=null===this.variant?"animated":"";return v(R||(R=$` <div class="relative"> <span class="opacity-0"><slot></slot></span> <div class="${0} ${0} rounded my-xs absolute inset-0"></div> </div> `),e,t)}}let P,V,q,G=e=>e;class N extends h{constructor(){super(...arguments),this.key=""}static get scopedElements(){return{"x-skeleton":O}}static get properties(){return e(e({},super.properties),{},{key:{type:String,reflect:!0},opts:{type:Object}})}static get styles(){return[super.styles,p(P||(P=G`:host{display:inline-block;color:inherit;line-height:inherit;font:inherit}`))]}get whenReady(){return this._whenI18nReady.then((()=>this.updateComplete))}render(){return this._isI18nReady?v(V||(V=G`${0}<slot></slot>`),this._t(this.key,this.opts)):v(q||(q=G`<x-skeleton class="block">${0}<slot></slot></x-skeleton>`),this.key)}}function W(...e){return e.filter((e=>!!e))}let F,H,z,K,U=e=>e;class Y extends h{constructor(){super(...arguments),this.disabled=!1,this.value=[]}static get scopedElements(){return{"x-i18n":N}}static get properties(){return e(e({},super.properties),{},{disabled:{type:Boolean},value:{type:Array}})}render(){const e=Y._allDays.map((e=>{try{return e.toLocaleString(this.lang,{minimumIntegerDigits:2})}catch(t){return e.toString()}}));return v(F||(F=U` <div class="space-y-s"> <div class="flex flex-wrap -mx-xs -mb-xs" style="max-width:364px;font-feature-settings:'tnum' 1"> ${0} </div> ${0} </div> `),Y._allDays.map(((t,n)=>v(H||(H=U` <label class="${0}"> ${0} <input type="checkbox" class="sr-only" ?disabled="${0}" ?checked="${0}" @change="${0}"> </label> `),this._getLabelClass(t),e[n],this.disabled,this.value.includes(t),(e=>this._handleChange(e,t))))),W(this.value.length>0&&v(z||(z=U` <p class="text-s text-tertiary leading-s"> <x-i18n key="monthday-picker.hint" .opts="${0}" .lang="${0}"> </x-i18n> ${0} </p> `),{days:this.value},this.lang,W([29,30,31].some((e=>this.value.includes(e)))&&v(K||(K=U`<x-i18n key="monthday-picker.warning" .lang="${0}"></x-i18n>`),this.lang)))))}_getLabelClass(e){let t="flex items-center justify-center m-xs p-s rounded text-m font-medium transition duration-200 sm-p-0 sm-h-m sm-w-l ";return this.value.includes(e)||(t+="bg-contrast-5 "),this._isI18nReady&&!this.disabled?(t+="cursor-pointer ",t+=this.value.includes(e)?"text-base ":"hover-bg-primary-10 ",e<29?(t+="focus-within-shadow-outline ",t+=this.value.includes(e)?"bg-primary":"text-body"):(t+="focus-within-shadow-outline-error ",t+=this.value.includes(e)?"bg-error":"text-error")):(t+="text-transparent ",this.value.includes(e)&&(t+=e<29?"bg-primary-50":"bg-error-10")),t}_handleChange(e,t){e.stopPropagation(),this._toggle(t),this._sendChange()}_sendChange(){this.dispatchEvent(new y(this.value))}_toggle(e){const t=this.value.indexOf(e);this.value=-1===t?[...this.value,e]:this.value.filter(((e,n)=>n!==t))}}Y._allDays=Array.from(new Array(31),((e,t)=>t+1));const J=document.createElement("template");function Z(e,t,n="long"){const s=new Date;for(;s.getDay()!==e;)s.setDate(s.getDate()+1);return s.toLocaleDateString(t,{weekday:n})}J.innerHTML='<dom-module id="lumo-badge">\n <template>\n <style>\n [theme~="badge"] {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n padding: 0.4em calc(0.5em + var(--lumo-border-radius-s) / 4);\n color: var(--lumo-primary-text-color);\n background-color: var(--lumo-primary-color-10pct);\n border-radius: var(--lumo-border-radius-s);\n font-family: var(--lumo-font-family);\n font-size: var(--lumo-font-size-s);\n line-height: 1;\n font-weight: 500;\n text-transform: initial;\n letter-spacing: initial;\n min-width: calc(var(--lumo-line-height-xs) * 1em + 0.45em);\n }\n\n /* Ensure proper vertical alignment */\n [theme~="badge"]::before {\n display: inline-block;\n content: "\\2003";\n width: 0;\n }\n\n [theme~="badge"][theme~="small"] {\n font-size: var(--lumo-font-size-xxs);\n line-height: 1;\n }\n\n /* Colors */\n\n [theme~="badge"][theme~="success"] {\n color: var(--lumo-success-text-color);\n background-color: var(--lumo-success-color-10pct);\n }\n\n [theme~="badge"][theme~="error"] {\n color: var(--lumo-error-text-color);\n background-color: var(--lumo-error-color-10pct);\n }\n\n [theme~="badge"][theme~="contrast"] {\n color: var(--lumo-contrast-80pct);\n background-color: var(--lumo-contrast-5pct);\n }\n\n /* Primary */\n\n [theme~="badge"][theme~="primary"] {\n color: var(--lumo-primary-contrast-color);\n background-color: var(--lumo-primary-color);\n }\n\n [theme~="badge"][theme~="success"][theme~="primary"] {\n color: var(--lumo-success-contrast-color);\n background-color: var(--lumo-success-color);\n }\n\n [theme~="badge"][theme~="error"][theme~="primary"] {\n color: var(--lumo-error-contrast-color);\n background-color: var(--lumo-error-color);\n }\n\n [theme~="badge"][theme~="contrast"][theme~="primary"] {\n color: var(--lumo-base-color);\n background-color: var(--lumo-contrast);\n }\n\n /* Links */\n\n [theme~="badge"][href]:hover {\n text-decoration: none;\n }\n\n /* Icon */\n\n [theme~="badge"] iron-icon {\n margin: -0.25em 0;\n --iron-icon-width: 1.5em;\n --iron-icon-height: 1.5em;\n }\n\n [theme~="badge"] iron-icon:first-child {\n margin-left: -0.375em;\n }\n\n [theme~="badge"] iron-icon:last-child {\n margin-right: -0.375em;\n }\n\n [theme~="badge"][icon] {\n min-width: 0;\n padding: 0;\n font-size: 1rem;\n --iron-icon-width: var(--lumo-icon-size-m);\n --iron-icon-height: var(--lumo-icon-size-m);\n }\n\n [theme~="badge"][icon][theme~="small"] {\n --iron-icon-width: var(--lumo-icon-size-s);\n --iron-icon-height: var(--lumo-icon-size-s);\n }\n\n /* Empty */\n\n [theme~="badge"]:not([icon]):empty {\n min-width: 0;\n width: 1em;\n height: 1em;\n padding: 0;\n border-radius: 50%;\n background-color: var(--lumo-primary-color);\n }\n\n [theme~="badge"][theme~="small"]:not([icon]):empty {\n width: 0.75em;\n height: 0.75em;\n }\n\n [theme~="badge"][theme~="contrast"]:not([icon]):empty {\n background-color: var(--lumo-contrast);\n }\n\n [theme~="badge"][theme~="success"]:not([icon]):empty {\n background-color: var(--lumo-success-color);\n }\n\n [theme~="badge"][theme~="error"]:not([icon]):empty {\n background-color: var(--lumo-error-color);\n }\n\n /* Pill */\n\n [theme~="badge"][theme~="pill"] {\n --lumo-border-radius-s: 1em;\n }\n\n /* RTL specific styles */\n\n [dir="rtl"][theme~="badge"] iron-icon:first-child {\n margin-right: -0.375em;\n margin-left: 0;\n }\n\n [dir="rtl"][theme~="badge"] iron-icon:last-child {\n margin-left: -0.375em;\n margin-right: 0;\n }\n </style>\n </template>\n</dom-module>',document.head.appendChild(J.content);let X,ee,te,ne=e=>e;class se extends Y{render(){return v(X||(X=ne` <div class="space-y-s"> <div class="flex flex-wrap -mx-xs -mb-xs text-m uppercase"> ${0} </div> ${0} </div> `),se._allDays.map((e=>v(ee||(ee=ne` <label class="${0}"> ${0} <input type="checkbox" class="sr-only" ?disabled="${0}" ?checked="${0}" @change="${0}"> </label> `),this._getLabelClass(e),Z(e,this.lang,"short"),this.disabled||!this._isI18nReady,this.value.includes(e),(t=>this._handleChange(t,e))))),W(this.value.length>0&&v(te||(te=ne` <p class="text-s text-tertiary leading-s"> <x-i18n key="weekday-picker.hint" .lang="${0}" .opts="${0}"> </x-i18n> </p> `),this.lang,{days:this.value})))}_getLabelClass(e){let t="flex items-center justify-center m-xs h-m w-xl rounded font-medium transition duration-200 ";return this._isI18nReady&&!this.disabled?(t+="cursor-pointer focus-within-shadow-outline ",t+=this.value.includes(e)?"text-base bg-primary":"bg-contrast-5 hover-bg-contrast-10 text-body"):(t+="text-transparent ",t+=this.value.includes(e)?"bg-primary-50":"bg-contrast-5"),t}_sendChange(){this.dispatchEvent(new _(this.value))}}se._allDays=new Array(7).fill(0).map(((e,t)=>t));export{j as D,N as I,Y as M,O as S,se as W,T as a,W as c,Z as t};
@@ -0,0 +1 @@
1
+ import"./shared-845f8bf1.js";import"./shared-6e977271.js";import"./shared-a0cbfb2f.js";import{I as e}from"./shared-befe135a.js";import{_ as s}from"./shared-11014aad.js";import{i}from"./shared-9803aa7c.js";import{h as t}from"./shared-dc73b9a5.js";let r,l,a,o=e=>e;customElements.define("foxy-internal-integer-control",class extends e{constructor(){super(...arguments),this.showControls=!1,this.prefix=null,this.suffix=null,this.min=null,this.max=null}static get properties(){return s(s({},super.properties),{},{showControls:{type:Boolean,attribute:"show-controls"},prefix:{},suffix:{},min:{type:Number},max:{type:Number}})}renderControl(){var e,s;return t(r||(r=o` <vaadin-integer-field error-message="${0}" placeholder="${0}" helper-text="${0}" label="${0}" class="w-full" min="${0}" max="${0}" ?has-controls="${0}" ?disabled="${0}" ?readonly="${0}" .checkValidity="${0}" .value="${0}" clear-button-visible @keydown="${0}" @change="${0}"> ${0} ${0} </vaadin-integer-field> `),i(this._errorMessage),this.placeholder,this.helperText,this.label,i(null!==(e=this.min)&&void 0!==e?e:void 0),i(null!==(s=this.max)&&void 0!==s?s:void 0),this.showControls,this.disabled,this.readonly,this._checkValidity,this._value,(e=>{var s;return"Enter"===e.key&&(null===(s=this.nucleon)||void 0===s?void 0:s.submit())}),(e=>{const s=e.currentTarget;this._value=parseInt(s.value)}),this.prefix?t(l||(l=o`<div slot="prefix">${0}</div>`),this.prefix):"",this.suffix?t(a||(a=o`<div class="pr-s font-medium" slot="suffix">${0}</div>`),this.suffix):"")}});
@@ -1 +1 @@
1
- import{T as e}from"./shared-56addb06.js";import{N as s}from"./shared-4fb9d21f.js";import{c as t}from"./shared-4e709717.js";import{h as i}from"./shared-dc73b9a5.js";let a,r,o=e=>e;class n extends(e(s)){renderBody(){return i(a||(a=o``))}render(){const e=this.in("fail")?"error":this.in({idle:"template"})?"empty":"busy";return i(r||(r=o` <div aria-busy="${0}" aria-live="polite" class="relative leading-m text-body text-m font-lumo"> <div class="${0}"> ${0} </div> <div class="${0}"> <foxy-spinner layout="${0}" state="${0}" class="m-auto" infer="spinner"> </foxy-spinner> </div> </div> `),this.in("busy"),t({"transition duration-500 ease-in-out":!0,"opacity-0 pointer-events-none":!this.isBodyReady}),this.renderBody(),t({"transition duration-500 ease-in-out absolute inset-0 flex":!0,"opacity-0 pointer-events-none":this.isBodyReady}),"busy"===e?"no-label":"horizontal",e)}get isBodyReady(){return!!this.data}}export{n as I};
1
+ import{T as e}from"./shared-56addb06.js";import{N as s}from"./shared-77fd8dae.js";import{c as t}from"./shared-4e709717.js";import{h as i}from"./shared-dc73b9a5.js";let a,r,o=e=>e;class n extends(e(s)){renderBody(){return i(a||(a=o``))}render(){const e=this.in("fail")?"error":this.in({idle:"template"})?"empty":"busy";return i(r||(r=o` <div aria-busy="${0}" aria-live="polite" class="relative leading-m text-body text-m font-lumo"> <div class="${0}"> ${0} </div> <div class="${0}"> <foxy-spinner layout="${0}" state="${0}" class="m-auto" infer="spinner"> </foxy-spinner> </div> </div> `),this.in("busy"),t({"transition duration-500 ease-in-out":!0,"opacity-0 pointer-events-none":!this.isBodyReady}),this.renderBody(),t({"transition duration-500 ease-in-out absolute inset-0 flex":!0,"opacity-0 pointer-events-none":this.isBodyReady}),"busy"===e?"no-label":"horizontal",e)}get isBodyReady(){return!!this.data}}export{n as I};
@@ -0,0 +1,64 @@
1
+ import"./shared-1d257548.js";import"./shared-7e201abd.js";import{_ as e}from"./shared-11014aad.js";import{s as l,h as t,c as a,L as s}from"./shared-dc73b9a5.js";import{o as n}from"./shared-8438d4ca.js";import{c as r}from"./shared-4e709717.js";import{i as o}from"./shared-9803aa7c.js";import{a as i}from"./shared-79d0699c.js";import{r as d}from"./shared-a0c6a159.js";import{R as u,T as c,a as v}from"./shared-56addb06.js";import{I as p}from"./shared-8def6325.js";import{C as b}from"./shared-6af480b8.js";var h,f;!function(e){e.Attribute="attribute",e.Boolean="boolean",e.String="string",e.Number="number",e.Date="date",e.Any="any"}(h||(h={})),function(e){e.LessThanOrEqual="lessthanorequal",e.LessThan="lessthan",e.GreaterThanOrEqual="greaterthanorequal",e.GreaterThan="greaterthan",e.IsDefined="isdefined",e.Not="not",e.In="in"}(f||(f={}));let g;const m=l(g||(g=(e=>e)`
2
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
3
+ <path d="M26.4 14.7399C26.4 15.2922 25.9523 15.7399 25.4 15.7399H10.6C10.0477 15.7399 9.60001 15.2922 9.60001 14.7399V14.2C9.60001 13.6477 10.0477 13.2 10.6 13.2H25.4C25.9523 13.2 26.4 13.6477 26.4 14.2V14.7399ZM26.4 21.8C26.4 22.3523 25.9523 22.8 25.4 22.8H10.6C10.0477 22.8 9.60001 22.3523 9.60001 21.8V21.2601C9.60001 20.7078 10.0477 20.2601 10.6 20.2601H25.4C25.9523 20.2601 26.4 20.7078 26.4 21.2601V21.8Z" class="fill-current"/>
4
+ </svg>
5
+ `));let C;const y=l(C||(C=(e=>e)`
6
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
7
+ <path d="M12.8656 14.6695C12.3425 14.4581 12 13.9503 12 13.386C12 12.3748 13.0489 11.7048 13.9663 12.1299L23.8937 16.7295C24.5323 17.0254 24.941 17.6652 24.941 18.369C24.941 19.0735 24.5316 19.7137 23.8921 20.0092L13.971 24.5938C13.0509 25.019 12 24.347 12 23.3334C12 22.7709 12.3394 22.264 12.8594 22.0496L21.341 18.3046L12.8656 14.6695Z" class="fill-current"/>
8
+ </svg>
9
+ `));let x;const w=l(x||(x=(e=>e)`
10
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
11
+ <path d="M12.5 9.8C11.0088 9.8 9.8 11.0088 9.8 12.5V23.5C9.8 24.9912 11.0088 26.2 12.5 26.2H14C14.6627 26.2 15.2 25.6627 15.2 25C15.2 24.3373 14.6627 23.8 14 23.8H13.5C12.782 23.8 12.2 23.218 12.2 22.5V13.5C12.2 12.782 12.782 12.2 13.5 12.2H14C14.6627 12.2 15.2 11.6627 15.2 11C15.2 10.3373 14.6627 9.8 14 9.8H12.5Z" class="fill-current"/>
12
+ <path d="M22 9.8C21.3373 9.8 20.8 10.3373 20.8 11C20.8 11.6627 21.3373 12.2 22 12.2H22.5C23.218 12.2 23.8 12.782 23.8 13.5V22.5C23.8 23.218 23.218 23.8 22.5 23.8H22C21.3373 23.8 20.8 24.3373 20.8 25C20.8 25.6627 21.3373 26.2 22 26.2H23.5C24.9912 26.2 26.2 24.9912 26.2 23.5V12.5C26.2 11.0088 24.9912 9.8 23.5 9.8H22Z" class="fill-current"/>
13
+ </svg>
14
+ `));let V;const $=l(V||(V=(e=>e)`
15
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
16
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M20.05 23.58L20.04 23.59L17.64 21.19L18.7 20.13L20.05 21.48L22.54 19L23.6 20.06L20.06 23.6L20.05 23.58ZM18 8C12.5 8 8 12.5 8 18C8 23.5 12.5 28 18 28C23.5 28 28 23.5 28 18C28 12.5 23.5 8 18 8ZM13.34 12.28L14.75 13.69L16.16 12.28L17.22 13.34L15.81 14.75L17.22 16.16L16.16 17.22L14.75 15.81L13.34 17.22L12.28 16.16L13.69 14.75L12.28 13.34L13.34 12.28ZM18 26C15.8 26 13.8 25.1 12.3 23.7L23.7 12.3C25.1 13.8 26 15.8 26 18C26 22.4 22.4 26 18 26Z" class="fill-current"/>
17
+ </svg>
18
+ `));let H;const L=l(H||(H=(e=>e)`
19
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
20
+ <path d="M22.8754 22.054C23.3985 22.2655 23.741 22.7733 23.741 23.3375C23.741 24.3487 22.6922 25.0187 21.7747 24.5936L11.8473 19.994C11.2087 19.6981 10.8 19.0583 10.8 18.3545C10.8 17.65 11.2094 17.0098 11.8489 16.7143L21.7701 12.1297C22.6902 11.7045 23.741 12.3765 23.741 13.3902C23.741 13.9526 23.4017 14.4596 22.8816 14.6739L14.4 18.4189L22.8754 22.054Z" class="fill-current"/>
21
+ </svg>
22
+ `));let M;const Z=l(M||(M=(e=>e)`
23
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
24
+ <path d="M22.8754 19.654C23.3985 19.8655 23.741 20.3733 23.741 20.9375C23.741 21.9487 22.6922 22.6187 21.7747 22.1936L11.8473 17.594C11.2087 17.2981 10.8 16.6584 10.8 15.9545C10.8 15.25 11.2094 14.6098 11.8489 14.3143L21.7701 9.72971C22.6902 9.30453 23.741 9.97655 23.741 10.9902C23.741 11.5527 23.4017 12.0596 22.8816 12.2739L14.4 16.0189L22.8754 19.654Z" class="fill-current"/>
25
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M10.9169 20.9941C11.2134 20.3281 11.9937 20.0286 12.6597 20.3251L22.8548 24.8643C23.5208 25.1608 23.8203 25.9411 23.5238 26.6071C23.2273 27.2731 22.447 27.5726 21.781 27.2761L11.5859 22.7369C10.9199 22.4404 10.6204 21.6601 10.9169 20.9941Z" class="fill-current"/>
26
+ </svg>
27
+ `));let O;const N=l(O||(O=(e=>e)`
28
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
29
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M24.0049 7.11C24.6649 7.49107 24.8911 8.33507 24.51 8.99511L13.1621 28.6503C12.781 29.3103 11.937 29.5365 11.277 29.1554C10.6169 28.7743 10.3908 27.9303 10.7719 27.2703L22.1198 7.61511C22.5009 6.95507 23.3448 6.72892 24.0049 7.11Z" class="fill-current"/>
30
+ <path d="M17.5097 13.2H10.8C10.1373 13.2 9.60001 13.7373 9.60001 14.4V14.5399C9.60001 15.2026 10.1373 15.7399 10.8 15.7399H16.0433L17.5097 13.2Z" class="fill-current"/>
31
+ <path d="M13.4336 20.2601H10.8C10.1373 20.2601 9.60001 20.7973 9.60001 21.4601V21.6C9.60001 22.2627 10.1373 22.8 10.8 22.8H11.9671L13.4336 20.2601Z" class="fill-current"/>
32
+ <path d="M17.9254 22.8H25.2C25.8627 22.8 26.4 22.2627 26.4 21.6V21.4601C26.4 20.7973 25.8627 20.2601 25.2 20.2601H19.3918L17.9254 22.8Z" class="fill-current"/>
33
+ <path d="M22.0015 15.7399H25.2C25.8627 15.7399 26.4 15.2026 26.4 14.5399V14.4C26.4 13.7373 25.8627 13.2 25.2 13.2H23.468L22.0015 15.7399Z" class="fill-current"/>
34
+ </svg>
35
+ `));let I;const j=l(I||(I=(e=>e)`
36
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
37
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M18 8C12.48 8 8 12.48 8 18C8 23.52 12.48 28 18 28C23.52 28 28 23.52 28 18C28 12.48 23.52 8 18 8ZM18 26C13.59 26 10 22.41 10 18C10 13.59 13.59 10 18 10C22.41 10 26 13.59 26 18C26 22.41 22.41 26 18 26Z" class="fill-current"/>
38
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M19.49 17.38C19.92 16.16 19.66 14.74 18.68 13.76C17.57 12.65 15.89 12.46 14.58 13.17L16.93 15.52L15.52 16.93L13.17 14.58C12.46 15.9 12.65 17.57 13.76 18.68C14.74 19.66 16.16 19.92 17.38 19.49L20.79 22.9C20.99 23.1 21.3 23.1 21.5 22.9L22.9 21.5C23.1 21.3 23.1 20.99 22.9 20.79L19.49 17.38Z" class="fill-current"/>
39
+ </svg>
40
+ `));let A;const T=l(A||(A=(e=>e)`
41
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
42
+ <path d="M10 13V15C10 15.55 9.55 16 9 16H8V20H9C9.55 20 10 20.45 10 21V23C10 24.65 11.35 26 13 26H16V24H13C12.45 24 12 23.55 12 23V21C12 19.7 11.16 18.58 10 18.17V17.83C11.16 17.42 12 16.3 12 15V13C12 12.45 12.45 12 13 12H16V10H13C11.35 10 10 11.35 10 13Z" class="fill-current"/>
43
+ <path d="M27 16C26.45 16 26 15.55 26 15V13C26 11.35 24.65 10 23 10H20V12H23C23.55 12 24 12.45 24 13V15C24 16.3 24.84 17.42 26 17.83V18.17C24.84 18.58 24 19.69 24 21V23C24 23.55 23.55 24 23 24H20V26H23C24.65 26 26 24.65 26 23V21C26 20.45 26.45 20 27 20H28V16H27Z" class="fill-current"/>
44
+ </svg>
45
+ `));let B;const D=l(B||(B=(e=>e)`
46
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
47
+ <path d="M23.8333 17.0588H22.0833V11.7647H20.3333V10H23.8333V17.0588Z" class="fill-current"/>
48
+ <path d="M15.6667 10H12.1667C11.525 10 11 10.5294 11 11.1765V15.8824C11 16.5294 11.525 17.0588 12.1667 17.0588H15.6667C16.3083 17.0588 16.8333 16.5294 16.8333 15.8824V11.1765C16.8333 10.5294 16.3083 10 15.6667 10ZM15.0833 15.2941H12.75V11.7647H15.0833V15.2941Z" class="fill-current"/>
49
+ <path d="M15.6667 26.4706H13.9167V21.1765H12.1667V19.4118H15.6667V26.4706Z" class="fill-current"/>
50
+ <path d="M23.8333 19.4118H20.3333C19.6917 19.4118 19.1667 19.9412 19.1667 20.5882V25.2941C19.1667 25.9412 19.6917 26.4706 20.3333 26.4706H23.8333C24.475 26.4706 25 25.9412 25 25.2941V20.5882C25 19.9412 24.475 19.4118 23.8333 19.4118ZM23.25 24.7059H20.9167V21.1765H23.25V24.7059Z" class="fill-current"/>
51
+ </svg>
52
+ `));let _;const q=l(_||(_=(e=>e)`
53
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
54
+ <path d="M25 10H24V8H22V10H14V8H12V10H11C9.89 10 9.01 10.9 9.01 12L9 26C9 27.1 9.89 28 11 28H25C26.1 28 27 27.1 27 26V12C27 10.9 26.1 10 25 10ZM25 26H11V16H25V26ZM25 14H11V12H25V14ZM23 19H18V24H23V19Z" class="fill-current"/>
55
+ </svg>
56
+ `));let E;const S=l(E||(E=(e=>e)`
57
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
58
+ <path d="M26.5 16L27 14H23L24 10H22L21 14H17L18 10H16L15 14H11L10.5 16H14.5L13.5 20H9.5L9 22H13L12 26H14L15 22H19L18 26H20L21 22H25L25.5 20H21.5L22.5 16H26.5ZM19.5 20H15.5L16.5 16H20.5L19.5 20Z" class="fill-current"/>
59
+ </svg>
60
+ `));let k;const z=l(k||(k=(e=>e)`
61
+ <svg class="w-full h-full" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
62
+ <path d="M11 11V14H16.5V26H19.5V14H25V11H11Z" class="fill-current"/>
63
+ </svg>
64
+ `));let R,U,G,W,F,Q=e=>e;function J(e){var l,a,s;const n=null===(a=null===(l=e.list)||void 0===l?void 0:l.every((l=>l.value!==e.value)))||void 0===a||a;return t(R||(R=Q` <label class="${0}"> <div class="relative flex-1 min-w-0 overflow-hidden"> <select class="${0}" ?disabled="${0}" @change="${0}"> ${0} ${0} </select> </div> ${0} </label> `),r({"flex items-center transition-colors group text-tertiary":!0,"cursor-pointer hover-bg-contrast-5":!e.disabled&&!e.readonly,"cursor-default":e.disabled||e.readonly}),r({"bg-transparent relative appearance-none flex h-m px-s":!0,"font-medium w-full max-w-full whitespace-nowrap focus-outline-none":!0,"text-tertiary":n&&!e.disabled,"text-body":!n&&!e.disabled&&!e.readonly,"text-disabled":e.disabled,"text-secondary":!n&&e.readonly,"cursor-pointer":!e.disabled&&!e.readonly,"cursor-default":e.disabled||e.readonly}),e.disabled||e.readonly,(l=>{const t=l.currentTarget,a=t.options[t.options.selectedIndex].value;e.onChange(a)}),n?t(U||(U=Q` <option value="" disabled="disabled" ?selected="${0}">${0}</option> `),n,e.t(e.label)):"",null===(s=e.list)||void 0===s?void 0:s.map((({label:l,value:a})=>t(G||(G=Q` <option value="${0}" ?selected="${0}"> ${0} </option> `),a,a===e.value,e.t(l)))),n?"":t(W||(W=Q` <span class="${0}"> ${0} </span> ${0} `),r({"font-tnum text-xs font-medium border mr-s px-xs rounded-s border-current inline-block":!0,"text-body":!e.disabled&&!e.readonly,"text-disabled":e.disabled,"text-secondary":e.readonly}),e.t(e.label),e.clearable&&!e.readonly?t(F||(F=Q` <button aria-label="${0}" class="${0}" ?disabled="${0}" @click="${0}"> <iron-icon aria-hidden="true" class="icon-inline text-l" icon="icons:remove-circle-outline"> </iron-icon> </button> `),e.t("delete"),r({"w-s h-s mr-xs flex items-center justify-center transition-colors rounded-full":!0,"focus-outline-none focus-ring-2 focus-ring-primary-50":!0,"hover-bg-contrast-5 hover-text-error text-body":!e.disabled,"text-disabled":e.disabled}),e.disabled,(()=>e.onChange(""))):""))}let K,P,X,Y,ee,le=e=>e;function te(e){var l;const a=`${null!==(l=e.id)&&void 0!==l?l:String(Math.floor(Math.random()*Math.pow(10,8)))}-list`,s=!!e.displayValue;let n=e.value;if("date"===e.type){const l=new Date(e.value);n=isNaN(l.getTime())?"":i(l)}return t(K||(K=le` <label class="relative flex items-center cursor-text group text-tertiary"> <div class="relative flex-1 min-w-0 overflow-hidden"> ${0} <input placeholder="${0}" class="${0}" list="${0}" type="${0}" max="${0}" .value="${0}" ?disabled="${0}" @input="${0}"> </div> <span class="${0}"> ${0} </span> ${0} ${0} </label> `),s?t(P||(P=le` <div aria-hidden="true" class="${0}"> <div class="truncate">${0}</div> </div> `),r({"absolute inset-0 h-m px-s font-medium flex items-center":!0,"text-body":!e.disabled&&!e.readonly,"text-disabled":e.disabled,"text-secondary":e.readonly}),e.t(e.displayValue)):"",n||"date"===e.type?"":e.t(e.label),r({"bg-base relative flex h-m px-s font-medium w-full":!0,"text-body":!e.disabled&&!e.readonly,"text-disabled":e.disabled,"text-secondary":e.readonly,"flex max-w-full whitespace-nowrap":!0,"focus-outline-none":!0,"opacity-0 focus-opacity-100":s}),o(e.list?a:void 0),"date"===e.type?"datetime-local":e.type,o("date"===e.type?"9999-12-31T23:59":""),n,e.disabled||e.readonly,(l=>{const t=l.currentTarget;let a=t.value;try{if("date"===e.type){const e=new Date(t.value);isNaN(e.getTime())||(a=e.toISOString())}}catch(e){}e.onChange(a)}),r({"font-tnum text-xs font-medium border border-current mr-s px-xs rounded-s":!0,"inline-block":!!n||"date"===e.type,"sr-only":!n&&"date"!==e.type,"text-body":!e.disabled&&!e.readonly,"text-disabled":e.disabled,"text-secondary":e.readonly}),e.t(e.label),e.list?t(X||(X=le` <datalist id="${0}"> ${0} </datalist> `),a,e.list.map((({label:l,value:a})=>t(Y||(Y=le`<option value="${0}">${0}</option>`),a,e.t(l))))):"",e.disabled||e.readonly?"":t(ee||(ee=le` <div class="absolute inset-0 transition-colors bg-transparent group-hover-bg-contrast-5 pointer-events-none"></div> `)))}let ae,se,ne=e=>e;let re,oe=e=>e;function ie({parsedValue:l,disabled:t,readonly:a,options:s,option:n,t:r,onChange:o}){return te({displayValue:null==n?void 0:n.label,disabled:t,readonly:a,value:l.path,label:"field",list:s.map((l=>e(e({},l),{},{value:l.path}))),type:"text",id:"path",t:r,onChange:e=>o({operator:null,value:"",path:e})})}let de,ue=e=>e;let ce,ve,pe=e=>e;function be(l){var a,s;const{parsedValue:o,isFullSize:i,isNested:u,readonly:c,disabled:v,options:p,t:b,onConvert:g,onDelete:C,onChange:x}=l,V=null!==(a=p.find((e=>e.path===o.path)))&&void 0!==a?a:null,H=null!==(s=null==V?void 0:V.type)&&void 0!==s?s:h.Any,M=o.operator,O={parsedValue:o,operators:l.operators,disabled:v,readonly:c,options:p,option:V,t:b,onChange:x},I={[h.Attribute]:T,[h.Boolean]:D,[h.Number]:S,[h.String]:z,[h.Date]:q,[h.Any]:j};return t(ce||(ce=pe` <div class="flex items-center space-x-s" aria-label="${0}"> <div class="${0}"> <div class="bg-contrast-10"> <div class="grid gap-1px grid-vertical sm-grid-horizontal"> <div class="bg-base" title="${0}"> <div class="${0}" aria-hidden="true"> ${0} </div> </div> <div class="bg-base"> ${0} </div> <div class="bg-base">${0}</div> <div class="bg-base"> ${0} </div> </div> </div> </div> <div class="${0}"> <button aria-label="${0}" class="${0}" ?disabled="${0}" @click="${0}"> <iron-icon aria-hidden="true" class="m-auto icon-inline text-xl" icon="icons:remove-circle-outline"> </iron-icon> </button> <button aria-label="${0}" class="${0}" ?disabled="${0}" @click="${0}"> <iron-icon aria-hidden="true" class="m-auto icon-inline text-xl" icon="icons:add-circle-outline"> </iron-icon> </button> </div> </div> `),b("query_builder_rule"),r({"flex-1 bg-base rounded overflow-hidden border":!0,"border-contrast-10":!u&&!c,"border-contrast-50":!!u||c,"border-dashed":c,"border-solid":!c}),b(`type_${H}`),r({"w-m h-m":!0,"text-tertiary":!c&&!v,"text-disabled":c||v}),V?I[H]:j,o.path&&(H===h.Attribute||o.name)?t(ve||(ve=pe` <div class="bg-contrast-10 grid gap-1px grid-cols-1 sm-grid-cols-2"> <div class="bg-base">${0}</div> <div class="bg-base">${0}</div> </div> `),ie(O),function(l){var t;return te({disabled:l.disabled,readonly:l.readonly,value:null!==(t=l.parsedValue.name)&&void 0!==t?t:"",label:"name",type:"text",t:l.t,onChange:t=>l.onChange(e(e({},l.parsedValue),{},{name:t}))})}(O)):ie(O),function(l){const a=l.parsedValue.operator,s={[f.GreaterThan]:y,[f.GreaterThanOrEqual]:n,[f.In]:w,[f.IsDefined]:$,[f.LessThan]:L,[f.LessThanOrEqual]:Z,[f.Not]:N},o={[h.Attribute]:[f.In,f.Not,f.IsDefined],[h.Boolean]:[],[h.String]:[f.In,f.Not],[h.Number]:[f.In,f.Not,f.GreaterThan,f.LessThan,f.GreaterThanOrEqual,f.LessThanOrEqual],[h.Date]:[f.In,f.Not],[h.Any]:Object.values(f)},i=(l.option?o[l.option.type]:l.parsedValue.name?Object.values(f):Object.values(f).filter((e=>e!==f.IsDefined))).filter((e=>l.operators.includes(e))),d=l.disabled||l.readonly||0===i.length||!l.parsedValue.path;return t(re||(re=oe` <button title="${0}" class="${0}" ?disabled="${0}" @click="${0}"> <div aria-hidden="true">${0}</div> </button> `),l.t(`operator_${null!=a?a:"equal"}`),r({"flex items-center justify-center w-m h-m transition-colors":!0,"focus-outline-none focus-ring-2 focus-ring-inset focus-ring-primary-50":!0,"text-body hover-bg-contrast-5":!d&&i.length>1,"cursor-default text-tertiary":!d&&i.length<=1,"text-disabled cursor-default":d}),d||i.length<=1,(()=>{var t;const s=a?i.indexOf(a):-1,n=null!==(t=i[s+1])&&void 0!==t?t:null;l.onChange(e(e({},l.parsedValue),{},{operator:n,value:l.parsedValue.value}))}),a?s[a]:m)}(O),M===f.In?function(l){var a,s,n,r;const o=(null===(a=l.option)||void 0===a?void 0:a.list)?J:te,i=l.parsedValue.value.split(","),u=null!==(n=null===(s=l.option)||void 0===s?void 0:s.type)&&void 0!==n?n:h.Any,c=u===h.Number?"number":u===h.Date?"date":"text",v=null===(r=l.option)||void 0===r?void 0:r.list,p=[...i.filter((e=>!!e))];return l.readonly||p.push(null),t(ae||(ae=ne` <div class="bg-contrast-10 grid grid-cols-1 gap-1px"> ${0} </div> `),d(p,((e,l)=>l),((a,s)=>{var n;return t(se||(se=ne` <div class="bg-base"> ${0} </div> `),o({type:c,list:v,t:l.t,value:null!=a?a:"",label:a?String(s+1):"add_value",disabled:l.disabled,readonly:l.readonly,clearable:!0,displayValue:null===(n=null==v?void 0:v.find((e=>e.value===a)))||void 0===n?void 0:n.label,onChange:t=>{t?i[s]=t:i.splice(s,1),l.onChange(e(e({},l.parsedValue),{},{value:i.join(",")}))}}))})))}(O):M===f.IsDefined?function(l){return J({readonly:l.readonly,disabled:l.disabled,value:l.parsedValue.value,label:"value",list:[{label:"is_defined_true",value:"true"},{label:"is_defined_false",value:"false"}],t:l.t,onChange:t=>l.onChange(e(e({},l.parsedValue),{},{value:t}))})}(O):H===h.Boolean?function(l){var t,a,s,n,r,o;const{parsedValue:i,option:d,readonly:u,disabled:c,t:v,onChange:p}=l,b=null!==(s=null===(a=null===(t=null==d?void 0:d.list)||void 0===t?void 0:t.find((e=>"false"===e.value)))||void 0===a?void 0:a.label)&&void 0!==s?s:"false",h=[{label:null!==(o=null===(r=null===(n=null==d?void 0:d.list)||void 0===n?void 0:n.find((e=>"true"===e.value)))||void 0===r?void 0:r.label)&&void 0!==o?o:"true",value:"true"},{label:b,value:"false"}];return J({disabled:c,readonly:u,value:i.value,label:"value",list:h,t:v,onChange:l=>p(e(e({},i),{},{value:l}))})}(O):null===M&&[h.Number,h.Date].includes(H)?function(l){var a,s,n;const{t:r,parsedValue:o,option:i,readonly:d,disabled:u,onChange:c}=l,v=o.value.split(".."),p=v.length>=1?v[0]:"",b=v.length>=2?v[1]:"",f=(null==i?void 0:i.list)?J:te,g=null!==(a=null==i?void 0:i.type)&&void 0!==a?a:h.Any,m=g===h.Number?"number":g===h.Date?"date":"text",C=null==i?void 0:i.list;return t(de||(de=ue` <div class="grid bg-contrast-10 gap-1px grid-cols-1 grid-rows-2 sm-grid-cols-2 sm-grid-rows-1"> <div class="bg-base"> ${0} </div> <div class="bg-base"> ${0} </div> </div> `),f({displayValue:null===(s=null==C?void 0:C.find((e=>e.value===p)))||void 0===s?void 0:s.label,readonly:d,disabled:u,value:p,label:"range_from",type:m,list:C,t:r,onChange:l=>c(e(e({},o),{},{value:`${l}..${b}`}))}),f({displayValue:null===(n=null==C?void 0:C.find((e=>e.value===b)))||void 0===n?void 0:n.label,readonly:d,disabled:u,label:"range_to",value:b,type:m,list:C,t:r,onChange:l=>c(e(e({},o),{},{value:`${p}..${l}`}))}))}(O):function(l){var t,a,s,n;const{t:r,option:o,parsedValue:i,readonly:d,disabled:u,onChange:c}=l,v=(null==o?void 0:o.list)?J:te,p=null!==(t=null==o?void 0:o.type)&&void 0!==t?t:h.Any;return v({displayValue:null===(s=null===(a=null==o?void 0:o.list)||void 0===a?void 0:a.find((e=>e.value===i.value)))||void 0===s?void 0:s.label,readonly:d,disabled:u||!i.path,value:null!==(n=i.value)&&void 0!==n?n:"",label:"value",type:p===h.Number?"number":p===h.Date?"date":"text",list:null==o?void 0:o.list,t:r,onChange:l=>c(e(e({},i),{},{value:l}))})}(O),r({"-mr-s self-start flex-col sm-flex-row flex-shrink-0 items-center":!0,"border-t border-b border-transparent divide-y divide-transparent":!0,hidden:!!i||c,flex:!i}),b("delete"),r({"box-content flex w-m h-m rounded-full transition-colors":!0,"text-secondary hover-bg-contrast-5 hover-text-error":!v,"cursor-default text-disabled":v,"focus-outline-none focus-ring-2 ring-primary-50":!0,"opacity-0":!o.path}),v||c||!o.path,C,b("add_or_clause"),r({"box-content flex w-m h-m rounded-full transition-colors":!0,"text-success hover-bg-contrast-5":!v,"cursor-default text-disabled":v,"focus-outline-none focus-ring-2 ring-primary-50":!0,"opacity-0":!o.path||!!u||l.disableOr}),v||c||!o.path,g)}let he,fe,ge,me,Ce=e=>e;function ye(l){const a=l.parsedValues.some((e=>Array.isArray(e))),s=t(he||(he=Ce`<div class="${0}"></div>`),a?"h-xs":"mt-s"),n=t(fe||(fe=Ce` <div class="flex items-center h-s"> <div class="w-m text-center leading-none uppercase font-medium text-xs text-contrast-30"> ${0} </div> <div class="flex-1 border-t border-contrast-20"></div> <div class="w-m ml-s flex-shrink-0"></div> <div class="hidden sm-block w-m flex-shrink-0"></div> </div> `),l.t("or"));return t(ge||(ge=Ce` <div aria-label="${0}"> ${0} </div> `),l.t("query_builder_group"),d([...l.parsedValues,null],((e,l)=>String(l)),((a,r)=>{const o=r>0?l.isNested?n:s:"";return null===a?[o,be({operators:l.operators,disableOr:l.disableOr,isFullSize:!l.isNested&&0===l.parsedValues.length,isNested:l.isNested,disabled:l.disabled,readonly:l.readonly,options:l.options,parsedValue:{path:"",operator:null,value:""},t:l.t,onChange:e=>l.onChange([...l.parsedValues,e])})]:Array.isArray(a)?[o,t(me||(me=Ce` <div class="bg-contrast-10 rounded-t-l rounded-b-l p-s -m-s"> ${0} </div> `),ye({parsedValues:a,disableOr:l.disableOr,operators:l.operators,isNested:!0,disabled:l.disabled,readonly:l.readonly,options:l.options,t:l.t,onChange:e=>{const t=[...l.parsedValues],a=e;t[r]=e.length>1?a:a[0],l.onChange(t)}}))]:[o,be({parsedValue:a,disableOr:l.disableOr,operators:l.operators,isNested:l.isNested,disabled:l.disabled,readonly:l.readonly,options:l.options,t:l.t,onChange:e=>{const t=[...l.parsedValues];t[r]=e,l.onChange(t)},onDelete:()=>{const e=l.parsedValues.filter(((e,l)=>l!==r));l.onChange(e)},onConvert:()=>{const t=[...l.parsedValues];t[r]=[a,e(e({},a),{},{operator:null,value:""})],l.onChange(t)}})]})))}function xe(e){var l;const[t,a]=e.split("=").map(decodeURIComponent),s=null!==(l=Object.values(f).find((e=>t.endsWith(`:${e}`))))&&void 0!==l?l:null;let n,r=t.substring(0,s?t.lastIndexOf(":"):void 0);const o=t.lastIndexOf("[");return r.endsWith("]")&&-1!==o&&(n=r.substring(o+1,r.length-1),r=r.substring(0,o),r.endsWith(":name")&&(r=r.substring(0,r.length-5))),{name:n,path:r,value:a,operator:s}}function we(e){let l=e.path;return e.name&&(l+=`:name[${e.name}]`),e.operator&&(l+=`:${e.operator}`),l=`${encodeURIComponent(l)}=${encodeURIComponent(e.value)}`,"="===l?"":l}function Ve(e){const l=e.reduce(((e,l)=>{if(Array.isArray(l)){const t=[l[0].value,l.slice(1).map((e=>we(e)))].join("|");e.push(`${l[0].path}=${encodeURIComponent(t)}`)}else"zoom"!==l.path&&e.push(we(l));return e}),[]),t=$e(e).join(",");return t&&l.push(`zoom=${encodeURIComponent(t)}`),l.join("&")}function $e(e){return e.map((e=>{if(Array.isArray(e))return $e(e);if(e.name)return[e.path];const l=e.path.split(":");return l.slice(0,l.length-1)})).flat().sort(((e,l)=>l.length-e.length)).filter(((e,l,t)=>t.every(((t,a)=>(a>=l||t!==e)&&!t.startsWith(`${e}:`)))))}let He;const Le=a(He||(He=(e=>e)`.gap-1px{gap:1px}.grid-vertical{grid-template:auto/var(--lumo-size-m) 1fr}:host([sm]) .sm-grid-horizontal{grid-template:auto/var(--lumo-size-m) 1fr var(--lumo-size-m) 1fr}`)),Me=b(u(c(v(p(s),"query-builder"))));class Ze extends Me{constructor(){super(...arguments),this.operators=Object.values(f),this.disableOr=!1,this.options=null,this.value=null}static get properties(){return e(e({},super.properties),{},{disableOr:{type:Boolean,attribute:"disable-or"},operators:{type:Array},options:{type:Array},value:{type:String}})}static get styles(){return[super.styles,Le]}render(){var e,l,t;const a=new Set(["zoom","limit","offset","order","fields"]),s=[],n=[];var r;return(r=null!==(e=this.value)&&void 0!==e?e:"",r.split("&").filter((e=>!!e)).map((e=>{const[l,t]=e.split("=").map(decodeURIComponent);return(null==t?void 0:t.includes("|"))?`${encodeURIComponent(l)}=${t}`.split("|").map((e=>xe(e))):xe(e)}))).forEach((e=>{Array.isArray(e)||!a.has(e.path)?n.push(e):s.push(e)})),ye({parsedValues:n,disableOr:this.disableOr,operators:null!==(l=this.operators)&&void 0!==l?l:[],disabled:this.disabled,readonly:this.readonly,options:null!==(t=this.options)&&void 0!==t?t:[],t:this.t.bind(this),onChange:e=>{this.value=Ve([...e,...s]),this.dispatchEvent(new Ze.ChangeEvent("change"))}})}}Ze.ChangeEvent=class extends CustomEvent{},Ze.Operator=f,Ze.Type=h,customElements.define("foxy-query-builder",Ze);export{f as O,Ze as Q,h as T};
@@ -1 +1 @@
1
- import{_ as e}from"./shared-11014aad.js";import{h as t}from"./shared-dc73b9a5.js";import{C as l}from"./shared-6af480b8.js";import"./foxy-nucleon-element.js";import{R as s,T as a,a as i}from"./shared-56addb06.js";import{c as r}from"./shared-4e709717.js";import{N as d}from"./shared-4fb9d21f.js";let n,o,h,c,m,u=e=>e;const b=l(s(a(i(d))));class p extends b{constructor(){super(...arguments),this.templates={},this.columns=[]}static get properties(){return e(e({},super.properties),{},{columns:{attribute:!1}})}render(){var e,l;const s=this.columns.some((e=>!!e.header));return t(n||(n=u` <div data-testid="wrapper" aria-busy="${0}" aria-live="polite" class="relative font-lumo text-m"> <table class="table-fixed w-full" data-testid="table"> <thead class="${0}"> <tr> ${0} </tr> </thead> <tbody class="divide-y divide-contrast-10"> ${0} </tbody> </table> ${0} </div> ${0} `),this.in("busy"),s?"border-b border-contrast-10":"sr-only",this.columns.map(((e,l)=>{var s;return t(o||(o=u` <th class="${0}"> ${0} </th> `),r({"truncate h-l text-tertiary text-m text-left font-medium":!0,"text-right":l===this.columns.length-1,"hidden sm-table-cell":"sm"===e.hideBelow,"hidden md-table-cell":"md"===e.hideBelow,"hidden lg-table-cell":"lg"===e.hideBelow,"hidden xl-table-cell":"xl"===e.hideBelow}),null===(s=e.header)||void 0===s?void 0:s.call(e,{html:t,lang:this.lang,data:this.data,ns:this.ns}))})),this.__rows.map((e=>{var l;return t(h||(h=u` <tr class="h-l"> ${0} </tr> `),null===(l=this.columns)||void 0===l?void 0:l.map(((l,s)=>{var a;return t(c||(c=u` <td class="${0}"> ${0} </td> `),r({"text-right":s===this.columns.length-1,"hidden sm-table-cell":"sm"===l.hideBelow,"hidden md-table-cell":"md"===l.hideBelow,"hidden lg-table-cell":"lg"===l.hideBelow,"hidden xl-table-cell":"xl"===l.hideBelow,"truncate h-l text-body":!0}),e?null===(a=l.cell)||void 0===a?void 0:a.call(l,{html:t,lang:this.lang,data:e,ns:this.ns}):"")})))})),this.in({idle:"snapshot"})?"":t(m||(m=u` <div class="absolute inset-0 flex items-center justify-center"> <foxy-spinner data-testid="spinner" layout="vertical" state="${0}" class="p-m bg-base shadow-xs rounded-t-l rounded-b-l" lang="${0}" ns="${0} ${0}"> </foxy-spinner> </div> `),this.in("busy")?"busy":this.in("idle")?"empty":"error",this.lang,this.ns,null!==(l=null===(e=customElements.get("foxy-spinner"))||void 0===e?void 0:e.defaultNS)&&void 0!==l?l:""),this.renderTemplateOrSlot())}get __rows(){var e,t,l;const s=Object.values(null!==(t=null===(e=this.data)||void 0===e?void 0:e._embedded)&&void 0!==t?t:{}).reduce(((e,t)=>[...e,...t]),[]);let a;if(0===s.length)try{const e=new URL(null!==(l=this.href)&&void 0!==l?l:"").searchParams.get("limit"),t=parseInt(null!=e?e:"");a=isNaN(t)?20:t}catch(e){a=20}else a=s.length;return new Array(a).fill(null).map(((e,t)=>{var l;return null!==(l=s[t])&&void 0!==l?l:e}))}}export{p as T};
1
+ import{_ as e}from"./shared-11014aad.js";import{h as t}from"./shared-dc73b9a5.js";import{C as l}from"./shared-6af480b8.js";import"./foxy-nucleon-element.js";import{R as s,T as a,a as i}from"./shared-56addb06.js";import{c as d}from"./shared-4e709717.js";import{N as r}from"./shared-77fd8dae.js";let n,o,h,c,m,u=e=>e;const b=l(s(a(i(r))));class p extends b{constructor(){super(...arguments),this.templates={},this.columns=[]}static get properties(){return e(e({},super.properties),{},{columns:{attribute:!1}})}render(){var e,l;const s=this.columns.some((e=>!!e.header));return t(n||(n=u` <div data-testid="wrapper" aria-busy="${0}" aria-live="polite" class="relative font-lumo text-m"> <table class="table-fixed w-full" data-testid="table"> <thead class="${0}"> <tr> ${0} </tr> </thead> <tbody class="divide-y divide-contrast-10"> ${0} </tbody> </table> ${0} </div> ${0} `),this.in("busy"),s?"border-b border-contrast-10":"sr-only",this.columns.map(((e,l)=>{var s;return t(o||(o=u` <th class="${0}"> ${0} </th> `),d({"truncate h-l text-tertiary text-m text-left font-medium":!0,"text-right":l===this.columns.length-1,"hidden sm-table-cell":"sm"===e.hideBelow,"hidden md-table-cell":"md"===e.hideBelow,"hidden lg-table-cell":"lg"===e.hideBelow,"hidden xl-table-cell":"xl"===e.hideBelow}),null===(s=e.header)||void 0===s?void 0:s.call(e,{html:t,lang:this.lang,data:this.data,ns:this.ns}))})),this.__rows.map((e=>{var l;return t(h||(h=u` <tr class="h-l"> ${0} </tr> `),null===(l=this.columns)||void 0===l?void 0:l.map(((l,s)=>{var a;return t(c||(c=u` <td class="${0}"> ${0} </td> `),d({"text-right":s===this.columns.length-1,"hidden sm-table-cell":"sm"===l.hideBelow,"hidden md-table-cell":"md"===l.hideBelow,"hidden lg-table-cell":"lg"===l.hideBelow,"hidden xl-table-cell":"xl"===l.hideBelow,"truncate h-l text-body":!0}),e?null===(a=l.cell)||void 0===a?void 0:a.call(l,{html:t,lang:this.lang,data:e,ns:this.ns}):"")})))})),this.in({idle:"snapshot"})?"":t(m||(m=u` <div class="absolute inset-0 flex items-center justify-center"> <foxy-spinner data-testid="spinner" layout="vertical" state="${0}" class="p-m bg-base shadow-xs rounded-t-l rounded-b-l" lang="${0}" ns="${0} ${0}"> </foxy-spinner> </div> `),this.in("busy")?"busy":this.in("idle")?"empty":"error",this.lang,this.ns,null!==(l=null===(e=customElements.get("foxy-spinner"))||void 0===e?void 0:e.defaultNS)&&void 0!==l?l:""),this.renderTemplateOrSlot())}get __rows(){var e,t,l;const s=Object.values(null!==(t=null===(e=this.data)||void 0===e?void 0:e._embedded)&&void 0!==t?t:{}).reduce(((e,t)=>[...e,...t]),[]);let a;if(0===s.length)try{const e=new URL(null!==(l=this.href)&&void 0!==l?l:"").searchParams.get("limit"),t=parseInt(null!=e?e:"");a=isNaN(t)?20:t}catch(e){a=20}else a=s.length;return new Array(a).fill(null).map(((e,t)=>{var l;return null!==(l=s[t])&&void 0!==l?l:e}))}}export{p as T};
@@ -1 +1 @@
1
- import{_ as e}from"./shared-11014aad.js";import"./shared-7e201abd.js";import"./shared-4877ed05.js";import"./shared-f2a8fb36.js";import{L as s,c as t,h as r}from"./shared-dc73b9a5.js";import{T as a}from"./shared-56addb06.js";import{c as i}from"./shared-4e709717.js";class o extends CustomEvent{constructor(e){super("change",{detail:e})}}let c,d,l=e=>e;class h extends(a(s)){constructor(){super(...arguments),this.readonly=!1,this.disabled=!1,this.checked=!1}static get properties(){return e(e({},super.properties),{},{readonly:{type:Boolean},disabled:{type:Boolean},checked:{type:Boolean}})}static get styles(){return[super.styles,t(c||(c=l`:host{--check-size:1.125rem}label{margin:calc(((1rem * var(--lumo-line-height-s)) - var(--check-size))/ -2) 0}label>:first-child{height:calc(1rem * var(--lumo-line-height-s))}.ml-xxl{margin-left:calc(var(--lumo-space-m) + var(--check-size))}.check{height:var(--check-size);width:var(--check-size)}`))]}render(){return r(d||(d=l` <label class="${0}"> <div class="flex items-center"> <div class="${0}"> <iron-icon icon="lumo:checkmark" class="${0}"> </iron-icon> <input type="checkbox" class="sr-only" .checked="${0}" ?disabled="${0}" data-testid="input" @change="${0}"> </div> </div> <div class="flex-1 font-lumo leading-s ml-m"> <slot></slot> </div> </label> <div class="${0}"> <slot name="content"></slot> </div> `),i({"flex items-start group transition-colors":!0,"cursor-default":this.disabled||this.readonly,"text-disabled":this.disabled,"text-secondary":this.readonly,"cursor-pointer":!this.disabled}),i({"flex-shrink-0 check transition-colors rounded-s border":!0,"focus-within-shadow-outline":!0,"bg-primary text-primary-contrast":!this.readonly&&this.checked,"border-dashed border-contrast-30":this.readonly,"border-transparent":!this.readonly,"opacity-50":this.disabled,"text-secondary bg-contrast-20":!this.readonly&&!this.checked,"group-hover-bg-contrast-30":!this.readonly&&!this.checked}),i({"block w-full h-full transition-transform transform":!0,"scale-100":this.checked,"scale-0":!this.checked}),this.checked,this.disabled,(e=>{if(this.readonly)return e.preventDefault();e.stopPropagation(),this.checked=!this.checked,this.dispatchEvent(new o(this.checked))}),i({"font-lumo ml-xxl transition-colors":!0,"text-disabled":this.disabled}))}}export{h as C,o as a};
1
+ import{_ as e}from"./shared-11014aad.js";import"./shared-7e201abd.js";import"./shared-4877ed05.js";import"./shared-f2a8fb36.js";import{L as s,c as t,h as r}from"./shared-dc73b9a5.js";import{T as a}from"./shared-56addb06.js";import{c as i}from"./shared-4e709717.js";class o extends CustomEvent{constructor(e){super("change",{detail:e})}}let c,d,l=e=>e;class h extends(a(s)){constructor(){super(...arguments),this.readonly=!1,this.disabled=!1,this.checked=!1}static get properties(){return e(e({},super.properties),{},{readonly:{type:Boolean},disabled:{type:Boolean},checked:{type:Boolean}})}static get styles(){return[super.styles,t(c||(c=l`:host{--check-size:1.125rem}label{margin:calc(((1rem * var(--lumo-line-height-s)) - var(--check-size))/ -2) 0}label>:first-child{height:calc(1rem * var(--lumo-line-height-s))}.ml-xxl{margin-left:calc(var(--lumo-space-m) + var(--check-size))}.check{height:var(--check-size);width:var(--check-size)}`))]}render(){return r(d||(d=l` <label class="${0}"> <div class="flex items-center"> <div class="${0}"> <iron-icon icon="lumo:checkmark" class="${0}"> </iron-icon> <input type="checkbox" class="sr-only" .checked="${0}" ?disabled="${0}" data-testid="input" @change="${0}"> </div> </div> <div class="flex-1 font-lumo leading-s ml-m"> <slot></slot> </div> </label> <div class="${0}"> <slot name="content"></slot> </div> `),i({"flex items-start group transition-colors":!0,"cursor-default":this.disabled||this.readonly,"text-disabled":this.disabled,"text-secondary":this.readonly,"cursor-pointer":!this.disabled}),i({"flex-shrink-0 check transition-colors rounded-s border":!0,"focus-within-shadow-outline":!0,"bg-primary text-primary-contrast":!this.readonly&&this.checked,"border-dashed border-contrast-30":this.readonly,"border-transparent":!this.readonly,"opacity-50":this.disabled,"text-secondary bg-contrast-20":!this.readonly&&!this.checked,"group-hover-bg-contrast-30":!this.readonly&&!this.checked}),i({"block w-full h-full transition-transform transform":!0,"scale-100":this.checked,"scale-0":!this.checked}),this.checked,this.disabled,(e=>{if(this.readonly)return e.preventDefault();e.stopPropagation(),this.checked=!this.checked,this.dispatchEvent(new o(this.checked))}),i({"font-lumo ml-xxl transition-colors":!0,"text-disabled":this.disabled}))}}export{h as C};