@feathery/react 2.12.2 → 2.12.3-pr-1522.4bcc507.0

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 (206) hide show
  1. package/dist/Form/index.d.ts.map +1 -1
  2. package/dist/Form/tests/testMocks.d.ts.map +1 -1
  3. package/dist/cjs/Form/index.d.ts.map +1 -1
  4. package/dist/cjs/Form/tests/testMocks.d.ts.map +1 -1
  5. package/dist/cjs/elements/fields/AddressLine1Field/tests/test-utils.d.ts +1 -0
  6. package/dist/cjs/elements/fields/AddressLine1Field/tests/test-utils.d.ts.map +1 -1
  7. package/dist/cjs/elements/fields/ButtonGroupField/tests/test-utils.d.ts +1 -0
  8. package/dist/cjs/elements/fields/ButtonGroupField/tests/test-utils.d.ts.map +1 -1
  9. package/dist/cjs/elements/fields/CheckboxField/tests/test-utils.d.ts +1 -0
  10. package/dist/cjs/elements/fields/CheckboxField/tests/test-utils.d.ts.map +1 -1
  11. package/dist/cjs/elements/fields/CheckboxGroupField/tests/test-utils.d.ts +1 -0
  12. package/dist/cjs/elements/fields/CheckboxGroupField/tests/test-utils.d.ts.map +1 -1
  13. package/dist/cjs/elements/fields/ColorPickerField/tests/test-utils.d.ts +1 -0
  14. package/dist/cjs/elements/fields/ColorPickerField/tests/test-utils.d.ts.map +1 -1
  15. package/dist/cjs/elements/fields/DateSelectorField/tests/test-utils.d.ts +1 -0
  16. package/dist/cjs/elements/fields/DateSelectorField/tests/test-utils.d.ts.map +1 -1
  17. package/dist/cjs/elements/fields/DropdownField/tests/test-utils.d.ts +2 -0
  18. package/dist/cjs/elements/fields/DropdownField/tests/test-utils.d.ts.map +1 -1
  19. package/dist/cjs/elements/fields/DropdownMultiField/tests/test-utils.d.ts +1 -0
  20. package/dist/cjs/elements/fields/DropdownMultiField/tests/test-utils.d.ts.map +1 -1
  21. package/dist/cjs/elements/fields/MatrixField/tests/test-utils.d.ts +1 -0
  22. package/dist/cjs/elements/fields/MatrixField/tests/test-utils.d.ts.map +1 -1
  23. package/dist/cjs/elements/fields/PasswordField/tests/test-utils.d.ts +1 -0
  24. package/dist/cjs/elements/fields/PasswordField/tests/test-utils.d.ts.map +1 -1
  25. package/dist/cjs/elements/fields/PhoneField/tests/test-utils.d.ts +1 -0
  26. package/dist/cjs/elements/fields/PhoneField/tests/test-utils.d.ts.map +1 -1
  27. package/dist/cjs/elements/fields/PinInputField/tests/test-utils.d.ts +1 -0
  28. package/dist/cjs/elements/fields/PinInputField/tests/test-utils.d.ts.map +1 -1
  29. package/dist/cjs/elements/fields/RadioButtonGroupField/tests/test-utils.d.ts +1 -0
  30. package/dist/cjs/elements/fields/RadioButtonGroupField/tests/test-utils.d.ts.map +1 -1
  31. package/dist/cjs/elements/fields/RatingField/tests/test-utils.d.ts +1 -0
  32. package/dist/cjs/elements/fields/RatingField/tests/test-utils.d.ts.map +1 -1
  33. package/dist/cjs/elements/fields/SliderField/tests/test-utils.d.ts +1 -0
  34. package/dist/cjs/elements/fields/SliderField/tests/test-utils.d.ts.map +1 -1
  35. package/dist/cjs/elements/fields/shared/tests/field-test-utils.d.ts +1 -0
  36. package/dist/cjs/elements/fields/shared/tests/field-test-utils.d.ts.map +1 -1
  37. package/dist/cjs/{fthry_FormControl.C6Rjgaho.js → fthry_FormControl.BkRkEOPV.js} +1 -1
  38. package/dist/cjs/{fthry_InlineTooltip.7d1XAj6X.js → fthry_InlineTooltip.CbVeAbj-.js} +2 -2
  39. package/dist/cjs/{fthry_Overlay.Bw-JWkvN.js → fthry_Overlay.zp3MDZez.js} +1 -1
  40. package/dist/cjs/{fthry_PaymentMethodField.DFPieFTd.js → fthry_PaymentMethodField.CJ8dq0fW.js} +4 -4
  41. package/dist/cjs/{fthry_Placeholder.DExePn4A.js → fthry_Placeholder.BmZn9eqe.js} +1 -1
  42. package/dist/cjs/{fthry_ShowEyeIcon.UMZgA8E5.js → fthry_ShowEyeIcon.Bm2XEOxd.js} +1 -1
  43. package/dist/cjs/{fthry_index.wQoLwNSA.js → fthry_index.B4YjC-C6.js} +3 -3
  44. package/dist/cjs/{fthry_index.C1oeAVTE.js → fthry_index.B9-9P9JF.js} +5 -5
  45. package/dist/cjs/{fthry_index.S5WoB9-i.js → fthry_index.BGZ09_Df.js} +4 -4
  46. package/dist/cjs/{fthry_index.DMvOdp_W.js → fthry_index.BHZiDOJy.js} +4 -4
  47. package/dist/cjs/{fthry_index.B6Z5Lnk8.js → fthry_index.BMG2-fL2.js} +1 -1
  48. package/dist/cjs/{fthry_index.BsqXL16P.js → fthry_index.BRcdDEP7.js} +5 -5
  49. package/dist/cjs/{fthry_index.CioaVxCu.js → fthry_index.BYMaOURT.js} +1 -1
  50. package/dist/cjs/{fthry_index.Bz0SR10h.js → fthry_index.Bc1WOCpN.js} +2 -2
  51. package/dist/cjs/{fthry_index.RgU7Oxrf.js → fthry_index.Bwkf_lk3.js} +953 -266
  52. package/dist/cjs/{fthry_index.KdnS_mBc.js → fthry_index.CAuvgDuG.js} +2 -2
  53. package/dist/cjs/{fthry_index.DZF8XXGF.js → fthry_index.CohzVLkQ.js} +4 -4
  54. package/dist/cjs/{fthry_index.Di_2sd1H.js → fthry_index.CtdngFQd.js} +81 -55
  55. package/dist/cjs/{fthry_index.YNi32Ez7.js → fthry_index.CzI9aLcM.js} +6 -6
  56. package/dist/cjs/{fthry_index.Cd5vLcwa.js → fthry_index.D6MKhV5W.js} +1 -1
  57. package/dist/cjs/{fthry_index.BnwtRb9Y.js → fthry_index.DHlxQYOY.js} +90 -63
  58. package/dist/cjs/{fthry_index.xtJFp2c_.js → fthry_index.DI7QOcRZ.js} +3 -3
  59. package/dist/cjs/{fthry_index.D1qaLv6Z.js → fthry_index.DNAP_k72.js} +8 -8
  60. package/dist/cjs/{fthry_index.DE7MeZLB.js → fthry_index.DRGdkWyD.js} +5 -5
  61. package/dist/cjs/{fthry_index.vmA_xfxy.js → fthry_index.DvJ038DD.js} +205 -71
  62. package/dist/cjs/{fthry_index.C_3RykNd.js → fthry_index.E_PMR0Yl.js} +1 -1
  63. package/dist/cjs/{fthry_index.CJZrrJii.js → fthry_index.fleNYFAW.js} +1 -1
  64. package/dist/cjs/{fthry_index.DX-1RJ2S.js → fthry_index.hn3nWnc7.js} +6 -6
  65. package/dist/cjs/{fthry_index.NNL4lQSw.js → fthry_index.sQV37Gt2.js} +1 -1
  66. package/dist/cjs/{fthry_input.DWFkBuAl.js → fthry_input.BhfAe7t1.js} +1 -1
  67. package/dist/cjs/{fthry_script.BVLKs7Gs.js → fthry_script.iSzGaCwW.js} +1 -1
  68. package/dist/cjs/{fthry_styles.B-tC_Abq.js → fthry_styles.CKZy9WDb.js} +1 -1
  69. package/dist/cjs/{fthry_useElementSize.BepGSP1Z.js → fthry_useElementSize.CUMmUgEh.js} +1 -1
  70. package/dist/cjs/{fthry_useSalesforceSync.DuaHbK7s.js → fthry_useSalesforceSync.DURMJ7-O.js} +1 -1
  71. package/dist/cjs/{fthry_webfontloader.D1tv1rM2.js → fthry_webfontloader.C04VodQo.js} +1 -1
  72. package/dist/cjs/index.d.ts +7 -0
  73. package/dist/cjs/index.d.ts.map +1 -1
  74. package/dist/cjs/index.js +1 -1
  75. package/dist/cjs/utils/featheryClient/index.d.ts +6 -0
  76. package/dist/cjs/utils/featheryClient/index.d.ts.map +1 -1
  77. package/dist/cjs/utils/formContext.d.ts +7 -0
  78. package/dist/cjs/utils/formContext.d.ts.map +1 -1
  79. package/dist/cjs/utils/internalState.d.ts +7 -0
  80. package/dist/cjs/utils/internalState.d.ts.map +1 -1
  81. package/dist/esm/Form/index.d.ts.map +1 -1
  82. package/dist/esm/Form/tests/testMocks.d.ts.map +1 -1
  83. package/dist/esm/elements/fields/AddressLine1Field/tests/test-utils.d.ts +1 -0
  84. package/dist/esm/elements/fields/AddressLine1Field/tests/test-utils.d.ts.map +1 -1
  85. package/dist/esm/elements/fields/ButtonGroupField/tests/test-utils.d.ts +1 -0
  86. package/dist/esm/elements/fields/ButtonGroupField/tests/test-utils.d.ts.map +1 -1
  87. package/dist/esm/elements/fields/CheckboxField/tests/test-utils.d.ts +1 -0
  88. package/dist/esm/elements/fields/CheckboxField/tests/test-utils.d.ts.map +1 -1
  89. package/dist/esm/elements/fields/CheckboxGroupField/tests/test-utils.d.ts +1 -0
  90. package/dist/esm/elements/fields/CheckboxGroupField/tests/test-utils.d.ts.map +1 -1
  91. package/dist/esm/elements/fields/ColorPickerField/tests/test-utils.d.ts +1 -0
  92. package/dist/esm/elements/fields/ColorPickerField/tests/test-utils.d.ts.map +1 -1
  93. package/dist/esm/elements/fields/DateSelectorField/tests/test-utils.d.ts +1 -0
  94. package/dist/esm/elements/fields/DateSelectorField/tests/test-utils.d.ts.map +1 -1
  95. package/dist/esm/elements/fields/DropdownField/tests/test-utils.d.ts +2 -0
  96. package/dist/esm/elements/fields/DropdownField/tests/test-utils.d.ts.map +1 -1
  97. package/dist/esm/elements/fields/DropdownMultiField/tests/test-utils.d.ts +1 -0
  98. package/dist/esm/elements/fields/DropdownMultiField/tests/test-utils.d.ts.map +1 -1
  99. package/dist/esm/elements/fields/MatrixField/tests/test-utils.d.ts +1 -0
  100. package/dist/esm/elements/fields/MatrixField/tests/test-utils.d.ts.map +1 -1
  101. package/dist/esm/elements/fields/PasswordField/tests/test-utils.d.ts +1 -0
  102. package/dist/esm/elements/fields/PasswordField/tests/test-utils.d.ts.map +1 -1
  103. package/dist/esm/elements/fields/PhoneField/tests/test-utils.d.ts +1 -0
  104. package/dist/esm/elements/fields/PhoneField/tests/test-utils.d.ts.map +1 -1
  105. package/dist/esm/elements/fields/PinInputField/tests/test-utils.d.ts +1 -0
  106. package/dist/esm/elements/fields/PinInputField/tests/test-utils.d.ts.map +1 -1
  107. package/dist/esm/elements/fields/RadioButtonGroupField/tests/test-utils.d.ts +1 -0
  108. package/dist/esm/elements/fields/RadioButtonGroupField/tests/test-utils.d.ts.map +1 -1
  109. package/dist/esm/elements/fields/RatingField/tests/test-utils.d.ts +1 -0
  110. package/dist/esm/elements/fields/RatingField/tests/test-utils.d.ts.map +1 -1
  111. package/dist/esm/elements/fields/SliderField/tests/test-utils.d.ts +1 -0
  112. package/dist/esm/elements/fields/SliderField/tests/test-utils.d.ts.map +1 -1
  113. package/dist/esm/elements/fields/shared/tests/field-test-utils.d.ts +1 -0
  114. package/dist/esm/elements/fields/shared/tests/field-test-utils.d.ts.map +1 -1
  115. package/dist/esm/{fthry_FormControl.D8Kuyg4Y.js → fthry_FormControl.DDAZFoSo.js} +1 -1
  116. package/dist/esm/{fthry_InlineTooltip.DLMOu2tO.js → fthry_InlineTooltip.DwsGjmPQ.js} +2 -2
  117. package/dist/esm/{fthry_Overlay.BaulbPVG.js → fthry_Overlay.DkCTSVzA.js} +1 -1
  118. package/dist/esm/{fthry_PaymentMethodField.E2VJPyju.js → fthry_PaymentMethodField.BgCHxykS.js} +4 -4
  119. package/dist/esm/{fthry_Placeholder.CY1XAzRf.js → fthry_Placeholder.BZZOH4gv.js} +1 -1
  120. package/dist/esm/{fthry_ShowEyeIcon.CCRFpPxr.js → fthry_ShowEyeIcon.FVKM_CUd.js} +1 -1
  121. package/dist/esm/{fthry_index.BeT6gsM_.js → fthry_index.3ZKChQii.js} +6 -6
  122. package/dist/esm/{fthry_index.DjW847uR.js → fthry_index.3bbiVByG.js} +1 -1
  123. package/dist/esm/{fthry_index.BgIsKSTD.js → fthry_index.BvXP5j-k.js} +3 -3
  124. package/dist/esm/{fthry_index.BU4BxoWO.js → fthry_index.Bzcb4acF.js} +2 -2
  125. package/dist/esm/{fthry_index.xfj1t0cY.js → fthry_index.C2vvoqul.js} +5 -5
  126. package/dist/esm/{fthry_index.B5ePXkSN.js → fthry_index.C5QJmvNS.js} +6 -6
  127. package/dist/esm/{fthry_index.Ds7JOYLz.js → fthry_index.C7bZ41Dr.js} +4 -4
  128. package/dist/esm/{fthry_index.Ca-06RMU.js → fthry_index.CLVY8zB_.js} +1 -1
  129. package/dist/esm/{fthry_index.DeT3UyJj.js → fthry_index.CRMp7Yug.js} +1 -1
  130. package/dist/esm/{fthry_index.7vZjIPEz.js → fthry_index.Cfs1JnS1.js} +4 -4
  131. package/dist/esm/{fthry_index.DsroTnQH.js → fthry_index.CgxfpBL9.js} +5 -5
  132. package/dist/esm/{fthry_index.2Gc_lB8n.js → fthry_index.ChZdNtIX.js} +81 -54
  133. package/dist/esm/{fthry_index.T_eziOjU.js → fthry_index.Cvc2tCaE.js} +1 -1
  134. package/dist/esm/{fthry_index.Dy33g5mc.js → fthry_index.DE7Dh4ea.js} +8 -8
  135. package/dist/esm/{fthry_index.wAyXRBo5.js → fthry_index.DbQ9ZgfN.js} +161 -27
  136. package/dist/esm/{fthry_index.6qFATni4.js → fthry_index.DnA1YwIh.js} +901 -214
  137. package/dist/esm/{fthry_index.nmBpjSD2.js → fthry_index.DtApOSy5.js} +1 -1
  138. package/dist/esm/{fthry_index.DIZWok9O.js → fthry_index.IEBDVXp5.js} +5 -5
  139. package/dist/esm/{fthry_index.Citw-wko.js → fthry_index.JlaR97bs.js} +1 -1
  140. package/dist/esm/{fthry_index.C90mmtNU.js → fthry_index.TccqLkT8.js} +4 -4
  141. package/dist/esm/{fthry_index.BBB2dAwJ.js → fthry_index.nBx09C9l.js} +3 -3
  142. package/dist/esm/{fthry_index.DbMs4N3L.js → fthry_index.pBPbV9ty.js} +2 -2
  143. package/dist/esm/{fthry_index.CugnxSkX.js → fthry_index.pN448hs2.js} +29 -2
  144. package/dist/esm/{fthry_input.Csm0akqb.js → fthry_input.DgpAkI4d.js} +1 -1
  145. package/dist/esm/{fthry_script.CTK4wksM.js → fthry_script.DNqAP9Nj.js} +1 -1
  146. package/dist/esm/{fthry_styles.BsiM2KXa.js → fthry_styles.BhmDd9Lo.js} +1 -1
  147. package/dist/esm/{fthry_useElementSize.BVooPdxW.js → fthry_useElementSize.CuzKKLqH.js} +1 -1
  148. package/dist/esm/{fthry_useSalesforceSync.DwvbAGUy.js → fthry_useSalesforceSync.D3lKBSsD.js} +1 -1
  149. package/dist/esm/{fthry_webfontloader.oZvuZxan.js → fthry_webfontloader.Bo43XEHO.js} +1 -1
  150. package/dist/esm/index.d.ts +7 -0
  151. package/dist/esm/index.d.ts.map +1 -1
  152. package/dist/esm/index.js +1 -1
  153. package/dist/esm/utils/featheryClient/index.d.ts +6 -0
  154. package/dist/esm/utils/featheryClient/index.d.ts.map +1 -1
  155. package/dist/esm/utils/formContext.d.ts +7 -0
  156. package/dist/esm/utils/formContext.d.ts.map +1 -1
  157. package/dist/esm/utils/internalState.d.ts +7 -0
  158. package/dist/esm/utils/internalState.d.ts.map +1 -1
  159. package/dist/index.d.ts +7 -0
  160. package/dist/index.d.ts.map +1 -1
  161. package/dist/utils/featheryClient/index.d.ts +6 -0
  162. package/dist/utils/featheryClient/index.d.ts.map +1 -1
  163. package/dist/utils/formContext.d.ts +7 -0
  164. package/dist/utils/formContext.d.ts.map +1 -1
  165. package/dist/utils/internalState.d.ts +7 -0
  166. package/dist/utils/internalState.d.ts.map +1 -1
  167. package/package.json +2 -2
  168. package/umd/{277.eceeb3ccb6328228b829.js → 277.94ae8bf6190836d1dceb.js} +1 -1
  169. package/umd/{466.2b6f52440bf8a6ee4f4d.js → 466.e3456c8b3407ad04ba56.js} +1 -1
  170. package/umd/509.4236d4d76d2fa2ccd971.js +2 -0
  171. package/umd/{509.f3c5235d7877c09fa946.js.LICENSE.txt → 509.4236d4d76d2fa2ccd971.js.LICENSE.txt} +5 -0
  172. package/umd/529.2bfdaee9e2bdc6d6c340.js +1 -0
  173. package/umd/{598.5c0785560cad57f12159.js → 598.ca92da6595afad37b511.js} +2 -2
  174. package/umd/{664.cce2aa2291d3323521b2.js → 664.42541009d1fcb121cc49.js} +1 -1
  175. package/umd/{94.3c0a220601820412e21e.js → 94.825cd88111c75098af1f.js} +1 -1
  176. package/umd/{AddressField.a7ec587f13a326e233de.js → AddressField.3523efd23175117d47a5.js} +1 -1
  177. package/umd/{ButtonGroupField.8a9cf493f8fb36ce3e85.js → ButtonGroupField.33cf9c939c8e82cc6c83.js} +1 -1
  178. package/umd/{CheckboxField.c4971d72024558868b02.js → CheckboxField.76c36941e86a62ec518d.js} +1 -1
  179. package/umd/{CheckboxGroupField.e5319cd7f814f9b626d7.js → CheckboxGroupField.b15705b46268e1142782.js} +1 -1
  180. package/umd/ColorPickerField.f6740bb7c4c20a520db5.js +1 -0
  181. package/umd/{CustomField.bf00bb9bdcd732c13171.js → CustomField.a5b2965922f2d170b9b5.js} +1 -1
  182. package/umd/{DateSelectorField.c193445e11fe4694b07a.js → DateSelectorField.00f321e0b1972feb9d69.js} +1 -1
  183. package/umd/{DropdownField.7081f67b0a39c49f1f3f.js → DropdownField.856b041871278f98e687.js} +1 -1
  184. package/umd/{DropdownMultiField.d2dc345e7bd0e32e76a7.js → DropdownMultiField.898572b300ad673a38c9.js} +1 -1
  185. package/umd/{FileUploadField.f51a675776b2947e79fa.js → FileUploadField.ea0067dd62b0454b7c2e.js} +1 -1
  186. package/umd/{MatrixField.007d30b45d438c773db7.js → MatrixField.f8624f3e59b21e04f368.js} +1 -1
  187. package/umd/{PasswordField.2147c784135a9369040c.js → PasswordField.1358356d6fbc6880f12a.js} +1 -1
  188. package/umd/{PaymentMethodField.a84c467c428712681821.js → PaymentMethodField.9a8e934f7450eb141217.js} +1 -1
  189. package/umd/{PhoneField.d43a22b1a4d92c618614.js → PhoneField.f52b5de44614b445feeb.js} +1 -1
  190. package/umd/{PinInputField.0f9ca456b79a9cdf2506.js → PinInputField.b1aee0ef9d3c9f9a1933.js} +1 -1
  191. package/umd/{QRScanner.5865f88b4a09f5e78c5b.js → QRScanner.3c22391de30dba001f13.js} +1 -1
  192. package/umd/{RadioButtonGroupField.7d81efb2ddc169916443.js → RadioButtonGroupField.38d62523106149c48f2e.js} +1 -1
  193. package/umd/{RatingField.104fa779291cd91ca8bc.js → RatingField.eeeb0ac499c308c120ba.js} +1 -1
  194. package/umd/{SignatureField.2cd57db4b52690a9650b.js → SignatureField.1b502b1edb19e4af3b64.js} +1 -1
  195. package/umd/{SliderField.b99f5928f7c1eaa08c3d.js → SliderField.a5ab58e4b89fa67d6ac6.js} +1 -1
  196. package/umd/{TextArea.0b440106b5f5a341ed74.js → TextArea.f566845d458d4c00e0e7.js} +1 -1
  197. package/umd/{TextField.9238b4371b974d4defd4.js → TextField.5a5296fe3ea60c4459f2.js} +1 -1
  198. package/umd/index.js +1 -1
  199. package/dist/cjs/fthry_floating-ui.utils.D2KLOgYj.js +0 -155
  200. package/dist/cjs/fthry_objectWithoutPropertiesLoose.BeCY0BVl.js +0 -32
  201. package/dist/esm/fthry_floating-ui.utils.tNaL8PGX.js +0 -136
  202. package/dist/esm/fthry_objectWithoutPropertiesLoose.BBpbdDOs.js +0 -29
  203. package/umd/509.f3c5235d7877c09fa946.js +0 -2
  204. package/umd/529.be48502b696e9179c151.js +0 -1
  205. package/umd/ColorPickerField.38edc699a89e4266e489.js +0 -1
  206. /package/umd/{598.5c0785560cad57f12159.js.LICENSE.txt → 598.ca92da6595afad37b511.js.LICENSE.txt} +0 -0
@@ -1,13 +1,11 @@
1
- import { y as middleware, z as stringify, A as rulesheet, B as weakMemoize, S as StyleSheet, R as RULESET, C as combine, H as match, I as serialize, J as copy, K as replace, W as WEBKIT, M as MOZ, L as MS, N as KEYFRAMES, O as DECLARATION, P as dealloc, Q as alloc, T as hash, U as charat, V as strlen, X as indexof, Y as next, Z as token, $ as from, a0 as peek, a1 as delimit, a2 as slice, a3 as position, a4 as compile, b as jsx$1, a as __assign, j as jsxs, m as Fragment$1, t as __rest, _ as __read, k as FORM_Z_INDEX, l as featheryWindow, s as featheryDoc, a5 as __spreadArray, u as useBorder, D as DROPDOWN_Z_INDEX } from './fthry_index.2Gc_lB8n.js';
1
+ import { y as stringify, z as rulesheet, C as COMMENT, A as middleware, R as RULESET, B as combine, H as match, I as serialize, J as copy, K as replace, W as WEBKIT, M as MOZ, L as MS, N as KEYFRAMES, O as DECLARATION, P as dealloc, Q as alloc, S as hash, T as charat, U as strlen, V as indexof, X as next, Y as token, Z as from, $ as peek, a0 as delimit, a1 as slice, a2 as position, a3 as compile, b as jsx$1, a as __assign, j as jsxs, m as Fragment$1, t as __rest, _ as __read, k as FORM_Z_INDEX, l as featheryWindow, s as featheryDoc, a4 as __spreadArray, u as useBorder, D as DROPDOWN_Z_INDEX } from './fthry_index.ChZdNtIX.js';
2
2
  import * as React from 'react';
3
3
  import { useState, useCallback, forwardRef, useContext, useLayoutEffect, useEffect, createContext, useRef, useMemo, Component, Fragment } from 'react';
4
- import { I as InlineTooltip } from './fthry_InlineTooltip.DLMOu2tO.js';
5
- import { P as Placeholder$2 } from './fthry_Placeholder.CY1XAzRf.js';
6
- import { u as useSalesforceSync } from './fthry_useSalesforceSync.DwvbAGUy.js';
7
- import { T as Tooltip, O as Overlay } from './fthry_Overlay.BaulbPVG.js';
8
- import { a as _objectWithoutPropertiesLoose, _ as _extends } from './fthry_objectWithoutPropertiesLoose.BBpbdDOs.js';
4
+ import { I as InlineTooltip } from './fthry_InlineTooltip.DwsGjmPQ.js';
5
+ import { P as Placeholder$2 } from './fthry_Placeholder.BZZOH4gv.js';
6
+ import { u as useSalesforceSync } from './fthry_useSalesforceSync.D3lKBSsD.js';
7
+ import { T as Tooltip, O as Overlay } from './fthry_Overlay.DkCTSVzA.js';
9
8
  import { createPortal } from 'react-dom';
10
- import { r as rectToClientRect } from './fthry_floating-ui.utils.tNaL8PGX.js';
11
9
  import 'react/jsx-runtime';
12
10
  import 'react-dom/client';
13
11
  import 'jszip';
@@ -93,9 +91,7 @@ function _iterableToArrayLimit(arr, i) {
93
91
  if (_x = (_i = _i.call(arr)).next, 0 === i) {
94
92
  if (Object(_i) !== _i) return;
95
93
  _n = !1;
96
- } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0) {
97
- ;
98
- }
94
+ } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0);
99
95
  } catch (err) {
100
96
  _d = true, _e = err;
101
97
  } finally {
@@ -111,9 +107,7 @@ function _iterableToArrayLimit(arr, i) {
111
107
 
112
108
  function _arrayLikeToArray(arr, len) {
113
109
  if (len == null || len > arr.length) len = arr.length;
114
- for (var i = 0, arr2 = new Array(len); i < len; i++) {
115
- arr2[i] = arr[i];
116
- }
110
+ for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
117
111
  return arr2;
118
112
  }
119
113
 
@@ -134,6 +128,19 @@ function _slicedToArray(arr, i) {
134
128
  return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
135
129
  }
136
130
 
131
+ function _objectWithoutPropertiesLoose(source, excluded) {
132
+ if (source == null) return {};
133
+ var target = {};
134
+ var sourceKeys = Object.keys(source);
135
+ var key, i;
136
+ for (i = 0; i < sourceKeys.length; i++) {
137
+ key = sourceKeys[i];
138
+ if (excluded.indexOf(key) >= 0) continue;
139
+ target[key] = source[key];
140
+ }
141
+ return target;
142
+ }
143
+
137
144
  function _objectWithoutProperties(source, excluded) {
138
145
  if (source == null) return {};
139
146
  var target = _objectWithoutPropertiesLoose(source, excluded);
@@ -217,6 +224,21 @@ function useStateManager(_ref) {
217
224
  });
218
225
  }
219
226
 
227
+ function _extends() {
228
+ _extends = Object.assign ? Object.assign.bind() : function (target) {
229
+ for (var i = 1; i < arguments.length; i++) {
230
+ var source = arguments[i];
231
+ for (var key in source) {
232
+ if (Object.prototype.hasOwnProperty.call(source, key)) {
233
+ target[key] = source[key];
234
+ }
235
+ }
236
+ }
237
+ return target;
238
+ };
239
+ return _extends.apply(this, arguments);
240
+ }
241
+
220
242
  function _classCallCheck(instance, Constructor) {
221
243
  if (!(instance instanceof Constructor)) {
222
244
  throw new TypeError("Cannot call a class as a function");
@@ -332,7 +354,175 @@ function _toConsumableArray(arr) {
332
354
  return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();
333
355
  }
334
356
 
335
- function memoize(fn) {
357
+ /*
358
+
359
+ Based off glamor's StyleSheet, thanks Sunil ❤️
360
+
361
+ high performance StyleSheet for css-in-js systems
362
+
363
+ - uses multiple style tags behind the scenes for millions of rules
364
+ - uses `insertRule` for appending in production for *much* faster performance
365
+
366
+ // usage
367
+
368
+ import { StyleSheet } from '@emotion/sheet'
369
+
370
+ let styleSheet = new StyleSheet({ key: '', container: document.head })
371
+
372
+ styleSheet.insert('#box { border: 1px solid red; }')
373
+ - appends a css rule into the stylesheet
374
+
375
+ styleSheet.flush()
376
+ - empties the stylesheet of all its contents
377
+
378
+ */
379
+ // $FlowFixMe
380
+ function sheetForTag(tag) {
381
+ if (tag.sheet) {
382
+ // $FlowFixMe
383
+ return tag.sheet;
384
+ } // this weirdness brought to you by firefox
385
+
386
+ /* istanbul ignore next */
387
+
388
+
389
+ for (var i = 0; i < document.styleSheets.length; i++) {
390
+ if (document.styleSheets[i].ownerNode === tag) {
391
+ // $FlowFixMe
392
+ return document.styleSheets[i];
393
+ }
394
+ }
395
+ }
396
+
397
+ function createStyleElement(options) {
398
+ var tag = document.createElement('style');
399
+ tag.setAttribute('data-emotion', options.key);
400
+
401
+ if (options.nonce !== undefined) {
402
+ tag.setAttribute('nonce', options.nonce);
403
+ }
404
+
405
+ tag.appendChild(document.createTextNode(''));
406
+ tag.setAttribute('data-s', '');
407
+ return tag;
408
+ }
409
+
410
+ var StyleSheet = /*#__PURE__*/function () {
411
+ // Using Node instead of HTMLElement since container may be a ShadowRoot
412
+ function StyleSheet(options) {
413
+ var _this = this;
414
+
415
+ this._insertTag = function (tag) {
416
+ var before;
417
+
418
+ if (_this.tags.length === 0) {
419
+ if (_this.insertionPoint) {
420
+ before = _this.insertionPoint.nextSibling;
421
+ } else if (_this.prepend) {
422
+ before = _this.container.firstChild;
423
+ } else {
424
+ before = _this.before;
425
+ }
426
+ } else {
427
+ before = _this.tags[_this.tags.length - 1].nextSibling;
428
+ }
429
+
430
+ _this.container.insertBefore(tag, before);
431
+
432
+ _this.tags.push(tag);
433
+ };
434
+
435
+ this.isSpeedy = options.speedy === undefined ? process.env.NODE_ENV === 'production' : options.speedy;
436
+ this.tags = [];
437
+ this.ctr = 0;
438
+ this.nonce = options.nonce; // key is the value of the data-emotion attribute, it's used to identify different sheets
439
+
440
+ this.key = options.key;
441
+ this.container = options.container;
442
+ this.prepend = options.prepend;
443
+ this.insertionPoint = options.insertionPoint;
444
+ this.before = null;
445
+ }
446
+
447
+ var _proto = StyleSheet.prototype;
448
+
449
+ _proto.hydrate = function hydrate(nodes) {
450
+ nodes.forEach(this._insertTag);
451
+ };
452
+
453
+ _proto.insert = function insert(rule) {
454
+ // the max length is how many rules we have per style tag, it's 65000 in speedy mode
455
+ // it's 1 in dev because we insert source maps that map a single rule to a location
456
+ // and you can only have one source map per style tag
457
+ if (this.ctr % (this.isSpeedy ? 65000 : 1) === 0) {
458
+ this._insertTag(createStyleElement(this));
459
+ }
460
+
461
+ var tag = this.tags[this.tags.length - 1];
462
+
463
+ if (process.env.NODE_ENV !== 'production') {
464
+ var isImportRule = rule.charCodeAt(0) === 64 && rule.charCodeAt(1) === 105;
465
+
466
+ if (isImportRule && this._alreadyInsertedOrderInsensitiveRule) {
467
+ // this would only cause problem in speedy mode
468
+ // but we don't want enabling speedy to affect the observable behavior
469
+ // so we report this error at all times
470
+ console.error("You're attempting to insert the following rule:\n" + rule + '\n\n`@import` rules must be before all other types of rules in a stylesheet but other rules have already been inserted. Please ensure that `@import` rules are before all other rules.');
471
+ }
472
+ this._alreadyInsertedOrderInsensitiveRule = this._alreadyInsertedOrderInsensitiveRule || !isImportRule;
473
+ }
474
+
475
+ if (this.isSpeedy) {
476
+ var sheet = sheetForTag(tag);
477
+
478
+ try {
479
+ // this is the ultrafast version, works across browsers
480
+ // the big drawback is that the css won't be editable in devtools
481
+ sheet.insertRule(rule, sheet.cssRules.length);
482
+ } catch (e) {
483
+ if (process.env.NODE_ENV !== 'production' && !/:(-moz-placeholder|-moz-focus-inner|-moz-focusring|-ms-input-placeholder|-moz-read-write|-moz-read-only|-ms-clear|-ms-expand|-ms-reveal){/.test(rule)) {
484
+ console.error("There was a problem inserting the following rule: \"" + rule + "\"", e);
485
+ }
486
+ }
487
+ } else {
488
+ tag.appendChild(document.createTextNode(rule));
489
+ }
490
+
491
+ this.ctr++;
492
+ };
493
+
494
+ _proto.flush = function flush() {
495
+ // $FlowFixMe
496
+ this.tags.forEach(function (tag) {
497
+ return tag.parentNode && tag.parentNode.removeChild(tag);
498
+ });
499
+ this.tags = [];
500
+ this.ctr = 0;
501
+
502
+ if (process.env.NODE_ENV !== 'production') {
503
+ this._alreadyInsertedOrderInsensitiveRule = false;
504
+ }
505
+ };
506
+
507
+ return StyleSheet;
508
+ }();
509
+
510
+ var weakMemoize = function weakMemoize(func) {
511
+ // $FlowFixMe flow doesn't include all non-primitive types as allowed for weakmaps
512
+ var cache = new WeakMap();
513
+ return function (arg) {
514
+ if (cache.has(arg)) {
515
+ // $FlowFixMe
516
+ return cache.get(arg);
517
+ }
518
+
519
+ var ret = func(arg);
520
+ cache.set(arg, ret);
521
+ return ret;
522
+ };
523
+ };
524
+
525
+ function memoize$1(fn) {
336
526
  var cache = Object.create(null);
337
527
  return function (arg) {
338
528
  if (cache[arg] === undefined) cache[arg] = fn(arg);
@@ -340,8 +530,6 @@ function memoize(fn) {
340
530
  };
341
531
  }
342
532
 
343
- var isBrowser$3 = typeof document !== 'undefined';
344
-
345
533
  var identifierWithPointTracking = function identifierWithPointTracking(begin, points, index) {
346
534
  var previous = 0;
347
535
  var character = 0;
@@ -466,6 +654,114 @@ var removeLabel = function removeLabel(element) {
466
654
  }
467
655
  }
468
656
  };
657
+ var ignoreFlag = 'emotion-disable-server-rendering-unsafe-selector-warning-please-do-not-use-this-the-warning-exists-for-a-reason';
658
+
659
+ var isIgnoringComment = function isIgnoringComment(element) {
660
+ return element.type === 'comm' && element.children.indexOf(ignoreFlag) > -1;
661
+ };
662
+
663
+ var createUnsafeSelectorsAlarm = function createUnsafeSelectorsAlarm(cache) {
664
+ return function (element, index, children) {
665
+ if (element.type !== 'rule' || cache.compat) return;
666
+ var unsafePseudoClasses = element.value.match(/(:first|:nth|:nth-last)-child/g);
667
+
668
+ if (unsafePseudoClasses) {
669
+ var isNested = !!element.parent; // in nested rules comments become children of the "auto-inserted" rule and that's always the `element.parent`
670
+ //
671
+ // considering this input:
672
+ // .a {
673
+ // .b /* comm */ {}
674
+ // color: hotpink;
675
+ // }
676
+ // we get output corresponding to this:
677
+ // .a {
678
+ // & {
679
+ // /* comm */
680
+ // color: hotpink;
681
+ // }
682
+ // .b {}
683
+ // }
684
+
685
+ var commentContainer = isNested ? element.parent.children : // global rule at the root level
686
+ children;
687
+
688
+ for (var i = commentContainer.length - 1; i >= 0; i--) {
689
+ var node = commentContainer[i];
690
+
691
+ if (node.line < element.line) {
692
+ break;
693
+ } // it is quite weird but comments are *usually* put at `column: element.column - 1`
694
+ // so we seek *from the end* for the node that is earlier than the rule's `element` and check that
695
+ // this will also match inputs like this:
696
+ // .a {
697
+ // /* comm */
698
+ // .b {}
699
+ // }
700
+ //
701
+ // but that is fine
702
+ //
703
+ // it would be the easiest to change the placement of the comment to be the first child of the rule:
704
+ // .a {
705
+ // .b { /* comm */ }
706
+ // }
707
+ // with such inputs we wouldn't have to search for the comment at all
708
+ // TODO: consider changing this comment placement in the next major version
709
+
710
+
711
+ if (node.column < element.column) {
712
+ if (isIgnoringComment(node)) {
713
+ return;
714
+ }
715
+
716
+ break;
717
+ }
718
+ }
719
+
720
+ unsafePseudoClasses.forEach(function (unsafePseudoClass) {
721
+ console.error("The pseudo class \"" + unsafePseudoClass + "\" is potentially unsafe when doing server-side rendering. Try changing it to \"" + unsafePseudoClass.split('-child')[0] + "-of-type\".");
722
+ });
723
+ }
724
+ };
725
+ };
726
+
727
+ var isImportRule = function isImportRule(element) {
728
+ return element.type.charCodeAt(1) === 105 && element.type.charCodeAt(0) === 64;
729
+ };
730
+
731
+ var isPrependedWithRegularRules = function isPrependedWithRegularRules(index, children) {
732
+ for (var i = index - 1; i >= 0; i--) {
733
+ if (!isImportRule(children[i])) {
734
+ return true;
735
+ }
736
+ }
737
+
738
+ return false;
739
+ }; // use this to remove incorrect elements from further processing
740
+ // so they don't get handed to the `sheet` (or anything else)
741
+ // as that could potentially lead to additional logs which in turn could be overhelming to the user
742
+
743
+
744
+ var nullifyElement = function nullifyElement(element) {
745
+ element.type = '';
746
+ element.value = '';
747
+ element["return"] = '';
748
+ element.children = '';
749
+ element.props = '';
750
+ };
751
+
752
+ var incorrectImportAlarm = function incorrectImportAlarm(element, index, children) {
753
+ if (!isImportRule(element)) {
754
+ return;
755
+ }
756
+
757
+ if (element.parent) {
758
+ console.error("`@import` rules can't be nested inside other rules. Please move it to the top level and put it before regular rules. Keep in mind that they can only be used within global styles.");
759
+ nullifyElement(element);
760
+ } else if (isPrependedWithRegularRules(index, children)) {
761
+ console.error("`@import` rules can't be after other rules. Please put your `@import` rules before your other rules.");
762
+ nullifyElement(element);
763
+ }
764
+ };
469
765
 
470
766
  /* eslint-disable no-fallthrough */
471
767
 
@@ -679,22 +975,9 @@ var prefixer = function prefixer(element, index, children, callback) {
679
975
  }
680
976
  };
681
977
 
682
- /* import type { StylisPlugin } from './types' */
683
-
684
- /*
685
- export type Options = {
686
- nonce?: string,
687
- stylisPlugins?: StylisPlugin[],
688
- key: string,
689
- container?: HTMLElement,
690
- speedy?: boolean,
691
- prepend?: boolean,
692
- insertionPoint?: HTMLElement
693
- }
694
- */
695
-
696
- var getServerStylisCache = isBrowser$3 ? undefined : weakMemoize(function () {
697
- return memoize(function () {
978
+ var isBrowser$4 = typeof document !== 'undefined';
979
+ var getServerStylisCache = isBrowser$4 ? undefined : weakMemoize(function () {
980
+ return memoize$1(function () {
698
981
  var cache = {};
699
982
  return function (name) {
700
983
  return cache[name];
@@ -703,22 +986,20 @@ var getServerStylisCache = isBrowser$3 ? undefined : weakMemoize(function () {
703
986
  });
704
987
  var defaultStylisPlugins = [prefixer];
705
988
 
706
- var createCache = function
707
- /*: EmotionCache */
708
- createCache(options
709
- /*: Options */
710
- ) {
989
+ var createCache = function createCache(options) {
711
990
  var key = options.key;
712
991
 
713
- if (isBrowser$3 && key === 'css') {
992
+ if (process.env.NODE_ENV !== 'production' && !key) {
993
+ throw new Error("You have to configure `key` for your cache. Please make sure it's unique (and not equal to 'css') as it's used for linking styles to your cache.\n" + "If multiple caches share the same key they might \"fight\" for each other's style elements.");
994
+ }
995
+
996
+ if (isBrowser$4 && key === 'css') {
714
997
  var ssrStyles = document.querySelectorAll("style[data-emotion]:not([data-s])"); // get SSRed styles out of the way of React's hydration
715
998
  // document.head is a safe place to move them to(though note document.head is not necessarily the last place they will be)
716
999
  // note this very very intentionally targets all style elements regardless of the key to ensure
717
1000
  // that creating a cache works inside of render of a React component
718
1001
 
719
- Array.prototype.forEach.call(ssrStyles, function (node
720
- /*: HTMLStyleElement */
721
- ) {
1002
+ Array.prototype.forEach.call(ssrStyles, function (node) {
722
1003
  // we want to only move elements which have a space in the data-emotion attribute value
723
1004
  // because that indicates that it is an Emotion 11 server-side rendered style elements
724
1005
  // while we will already ignore Emotion 11 client-side inserted styles because of the :not([data-s]) part in the selector
@@ -730,7 +1011,6 @@ createCache(options
730
1011
  if (dataEmotionAttribute.indexOf(' ') === -1) {
731
1012
  return;
732
1013
  }
733
-
734
1014
  document.head.appendChild(node);
735
1015
  node.setAttribute('data-s', '');
736
1016
  });
@@ -738,20 +1018,23 @@ createCache(options
738
1018
 
739
1019
  var stylisPlugins = options.stylisPlugins || defaultStylisPlugins;
740
1020
 
1021
+ if (process.env.NODE_ENV !== 'production') {
1022
+ // $FlowFixMe
1023
+ if (/[^a-z-]/.test(key)) {
1024
+ throw new Error("Emotion key must only contain lower case alphabetical characters and - but \"" + key + "\" was passed");
1025
+ }
1026
+ }
1027
+
741
1028
  var inserted = {};
742
1029
  var container;
743
- /* : Node */
744
-
745
1030
  var nodesToHydrate = [];
746
1031
 
747
- if (isBrowser$3) {
1032
+ if (isBrowser$4) {
748
1033
  container = options.container || document.head;
749
1034
  Array.prototype.forEach.call( // this means we will ignore elements which don't have a space in them which
750
1035
  // means that the style elements we're looking at are only Emotion 11 server-rendered style elements
751
- document.querySelectorAll("style[data-emotion^=\"" + key + " \"]"), function (node
752
- /*: HTMLStyleElement */
753
- ) {
754
- var attrib = node.getAttribute("data-emotion").split(' ');
1036
+ document.querySelectorAll("style[data-emotion^=\"" + key + " \"]"), function (node) {
1037
+ var attrib = node.getAttribute("data-emotion").split(' '); // $FlowFixMe
755
1038
 
756
1039
  for (var i = 1; i < attrib.length; i++) {
757
1040
  inserted[attrib[i]] = true;
@@ -762,19 +1045,31 @@ createCache(options
762
1045
  }
763
1046
 
764
1047
  var _insert;
765
- /*: (
766
- selector: string,
767
- serialized: SerializedStyles,
768
- sheet: StyleSheet,
769
- shouldCache: boolean
770
- ) => string | void */
771
-
772
1048
 
773
1049
  var omnipresentPlugins = [compat, removeLabel];
774
1050
 
775
- if (isBrowser$3) {
1051
+ if (process.env.NODE_ENV !== 'production') {
1052
+ omnipresentPlugins.push(createUnsafeSelectorsAlarm({
1053
+ get compat() {
1054
+ return cache.compat;
1055
+ }
1056
+
1057
+ }), incorrectImportAlarm);
1058
+ }
1059
+
1060
+ if (isBrowser$4) {
776
1061
  var currentSheet;
777
- var finalizingPlugins = [stringify, rulesheet(function (rule) {
1062
+ var finalizingPlugins = [stringify, process.env.NODE_ENV !== 'production' ? function (element) {
1063
+ if (!element.root) {
1064
+ if (element["return"]) {
1065
+ currentSheet.insert(element["return"]);
1066
+ } else if (element.value && element.type !== COMMENT) {
1067
+ // insert empty rule in non-production environments
1068
+ // so @emotion/jest can grab `key` from the (JS)DOM for caches without any rules inserted yet
1069
+ currentSheet.insert(element.value + "{}");
1070
+ }
1071
+ }
1072
+ } : rulesheet(function (rule) {
778
1073
  currentSheet.insert(rule);
779
1074
  })];
780
1075
  var serializer = middleware(omnipresentPlugins.concat(stylisPlugins, finalizingPlugins));
@@ -783,19 +1078,17 @@ createCache(options
783
1078
  return serialize(compile(styles), serializer);
784
1079
  };
785
1080
 
786
- _insert = function
787
- /*: void */
788
- insert(selector
789
- /*: string */
790
- , serialized
791
- /*: SerializedStyles */
792
- , sheet
793
- /*: StyleSheet */
794
- , shouldCache
795
- /*: boolean */
796
- ) {
1081
+ _insert = function insert(selector, serialized, sheet, shouldCache) {
797
1082
  currentSheet = sheet;
798
1083
 
1084
+ if (process.env.NODE_ENV !== 'production' && serialized.map !== undefined) {
1085
+ currentSheet = {
1086
+ insert: function insert(rule) {
1087
+ sheet.insert(rule + serialized.map);
1088
+ }
1089
+ };
1090
+ }
1091
+
799
1092
  stylis(selector ? selector + "{" + serialized.styles + "}" : serialized.styles);
800
1093
 
801
1094
  if (shouldCache) {
@@ -809,17 +1102,12 @@ createCache(options
809
1102
 
810
1103
  var _stylis = function _stylis(styles) {
811
1104
  return serialize(compile(styles), _serializer);
812
- };
1105
+ }; // $FlowFixMe
1106
+
813
1107
 
814
1108
  var serverStylisCache = getServerStylisCache(stylisPlugins)(key);
815
1109
 
816
- var getRules = function
817
- /*: string */
818
- getRules(selector
819
- /*: string */
820
- , serialized
821
- /*: SerializedStyles */
822
- ) {
1110
+ var getRules = function getRules(selector, serialized) {
823
1111
  var name = serialized.name;
824
1112
 
825
1113
  if (serverStylisCache[name] === undefined) {
@@ -829,17 +1117,7 @@ createCache(options
829
1117
  return serverStylisCache[name];
830
1118
  };
831
1119
 
832
- _insert = function
833
- /*: string | void */
834
- _insert(selector
835
- /*: string */
836
- , serialized
837
- /*: SerializedStyles */
838
- , sheet
839
- /*: StyleSheet */
840
- , shouldCache
841
- /*: boolean */
842
- ) {
1120
+ _insert = function _insert(selector, serialized, sheet, shouldCache) {
843
1121
  var name = serialized.name;
844
1122
  var rules = getRules(selector, serialized);
845
1123
 
@@ -851,6 +1129,12 @@ createCache(options
851
1129
  cache.inserted[name] = true;
852
1130
  }
853
1131
 
1132
+ if ( // using === development instead of !== production
1133
+ // because if people do ssr in tests, the source maps showing up would be annoying
1134
+ process.env.NODE_ENV === 'development' && serialized.map !== undefined) {
1135
+ return rules + serialized.map;
1136
+ }
1137
+
854
1138
  return rules;
855
1139
  } else {
856
1140
  // in compat mode, we put the styles on the inserted cache so
@@ -869,9 +1153,7 @@ createCache(options
869
1153
  };
870
1154
  }
871
1155
 
872
- var cache
873
- /*: EmotionCache */
874
- = {
1156
+ var cache = {
875
1157
  key: key,
876
1158
  sheet: new StyleSheet({
877
1159
  key: key,
@@ -890,8 +1172,7 @@ createCache(options
890
1172
  return cache;
891
1173
  };
892
1174
 
893
- var isBrowser$2 = typeof document !== 'undefined';
894
-
1175
+ var isBrowser$3 = typeof document !== 'undefined';
895
1176
  function getRegisteredStyles(registered, registeredStyles, classNames) {
896
1177
  var rawClassName = '';
897
1178
  classNames.split(' ').forEach(function (className) {
@@ -915,7 +1196,7 @@ var registerStyles = function registerStyles(cache, serialized, isStringTag) {
915
1196
  // in node since emotion-server relies on whether a style is in
916
1197
  // the registered cache to know whether a style is global or not
917
1198
  // also, note that this check will be dead code eliminated in the browser
918
- isBrowser$2 === false && cache.compat !== undefined) && cache.registered[className] === undefined) {
1199
+ isBrowser$3 === false && cache.compat !== undefined) && cache.registered[className] === undefined) {
919
1200
  cache.registered[className] = serialized.styles;
920
1201
  }
921
1202
  };
@@ -930,14 +1211,14 @@ var insertStyles = function insertStyles(cache, serialized, isStringTag) {
930
1211
  do {
931
1212
  var maybeStyles = cache.insert(serialized === current ? "." + className : '', current, cache.sheet, true);
932
1213
 
933
- if (!isBrowser$2 && maybeStyles !== undefined) {
1214
+ if (!isBrowser$3 && maybeStyles !== undefined) {
934
1215
  stylesForSSR += maybeStyles;
935
1216
  }
936
1217
 
937
1218
  current = current.next;
938
1219
  } while (current !== undefined);
939
1220
 
940
- if (!isBrowser$2 && stylesForSSR.length !== 0) {
1221
+ if (!isBrowser$3 && stylesForSSR.length !== 0) {
941
1222
  return stylesForSSR;
942
1223
  }
943
1224
  }
@@ -1047,6 +1328,16 @@ var unitlessKeys = {
1047
1328
  strokeWidth: 1
1048
1329
  };
1049
1330
 
1331
+ function memoize(fn) {
1332
+ var cache = Object.create(null);
1333
+ return function (arg) {
1334
+ if (cache[arg] === undefined) cache[arg] = fn(arg);
1335
+ return cache[arg];
1336
+ };
1337
+ }
1338
+
1339
+ var ILLEGAL_ESCAPE_SEQUENCE_ERROR = "You have illegal escape sequence in your template literal, most likely inside content's property value.\nBecause you write your CSS inside a JavaScript string you actually have to do double escaping, so for example \"content: '\\00d7';\" should become \"content: '\\\\00d7';\".\nYou can read more about this here:\nhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals#ES2018_revision_of_illegal_escape_sequences";
1340
+ var UNDEFINED_AS_OBJECT_KEY_ERROR = "You have passed in falsy value as style object's key (can happen when in example you pass unexported component as computed key).";
1050
1341
  var hyphenateRegex = /[A-Z]|^ms/g;
1051
1342
  var animationRegex = /_EMO_([^_]+?)_([^]*?)_EMO_/g;
1052
1343
 
@@ -1087,16 +1378,47 @@ var processStyleValue = function processStyleValue(key, value) {
1087
1378
  return value;
1088
1379
  };
1089
1380
 
1381
+ if (process.env.NODE_ENV !== 'production') {
1382
+ var contentValuePattern = /(var|attr|counters?|url|element|(((repeating-)?(linear|radial))|conic)-gradient)\(|(no-)?(open|close)-quote/;
1383
+ var contentValues = ['normal', 'none', 'initial', 'inherit', 'unset'];
1384
+ var oldProcessStyleValue = processStyleValue;
1385
+ var msPattern = /^-ms-/;
1386
+ var hyphenPattern = /-(.)/g;
1387
+ var hyphenatedCache = {};
1388
+
1389
+ processStyleValue = function processStyleValue(key, value) {
1390
+ if (key === 'content') {
1391
+ if (typeof value !== 'string' || contentValues.indexOf(value) === -1 && !contentValuePattern.test(value) && (value.charAt(0) !== value.charAt(value.length - 1) || value.charAt(0) !== '"' && value.charAt(0) !== "'")) {
1392
+ throw new Error("You seem to be using a value for 'content' without quotes, try replacing it with `content: '\"" + value + "\"'`");
1393
+ }
1394
+ }
1395
+
1396
+ var processed = oldProcessStyleValue(key, value);
1397
+
1398
+ if (processed !== '' && !isCustomProperty(key) && key.indexOf('-') !== -1 && hyphenatedCache[key] === undefined) {
1399
+ hyphenatedCache[key] = true;
1400
+ console.error("Using kebab-case for css properties in objects is not supported. Did you mean " + key.replace(msPattern, 'ms-').replace(hyphenPattern, function (str, _char) {
1401
+ return _char.toUpperCase();
1402
+ }) + "?");
1403
+ }
1404
+
1405
+ return processed;
1406
+ };
1407
+ }
1408
+
1409
+ var noComponentSelectorMessage = 'Component selectors can only be used in conjunction with ' + '@emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware ' + 'compiler transform.';
1410
+
1090
1411
  function handleInterpolation(mergedProps, registered, interpolation) {
1091
1412
  if (interpolation == null) {
1092
1413
  return '';
1093
1414
  }
1094
1415
 
1095
- var componentSelector = interpolation;
1096
-
1097
- if (componentSelector.__emotion_styles !== undefined) {
1416
+ if (interpolation.__emotion_styles !== undefined) {
1417
+ if (process.env.NODE_ENV !== 'production' && interpolation.toString() === 'NO_COMPONENT_SELECTOR') {
1418
+ throw new Error(noComponentSelectorMessage);
1419
+ }
1098
1420
 
1099
- return componentSelector;
1421
+ return interpolation;
1100
1422
  }
1101
1423
 
1102
1424
  switch (typeof interpolation) {
@@ -1107,21 +1429,17 @@ function handleInterpolation(mergedProps, registered, interpolation) {
1107
1429
 
1108
1430
  case 'object':
1109
1431
  {
1110
- var keyframes = interpolation;
1111
-
1112
- if (keyframes.anim === 1) {
1432
+ if (interpolation.anim === 1) {
1113
1433
  cursor = {
1114
- name: keyframes.name,
1115
- styles: keyframes.styles,
1434
+ name: interpolation.name,
1435
+ styles: interpolation.styles,
1116
1436
  next: cursor
1117
1437
  };
1118
- return keyframes.name;
1438
+ return interpolation.name;
1119
1439
  }
1120
1440
 
1121
- var serializedStyles = interpolation;
1122
-
1123
- if (serializedStyles.styles !== undefined) {
1124
- var next = serializedStyles.next;
1441
+ if (interpolation.styles !== undefined) {
1442
+ var next = interpolation.next;
1125
1443
 
1126
1444
  if (next !== undefined) {
1127
1445
  // not the most efficient thing ever but this is a pretty rare case
@@ -1136,7 +1454,11 @@ function handleInterpolation(mergedProps, registered, interpolation) {
1136
1454
  }
1137
1455
  }
1138
1456
 
1139
- var styles = serializedStyles.styles + ";";
1457
+ var styles = interpolation.styles + ";";
1458
+
1459
+ if (process.env.NODE_ENV !== 'production' && interpolation.map !== undefined) {
1460
+ styles += interpolation.map;
1461
+ }
1140
1462
 
1141
1463
  return styles;
1142
1464
  }
@@ -1151,18 +1473,37 @@ function handleInterpolation(mergedProps, registered, interpolation) {
1151
1473
  var result = interpolation(mergedProps);
1152
1474
  cursor = previousCursor;
1153
1475
  return handleInterpolation(mergedProps, registered, result);
1476
+ } else if (process.env.NODE_ENV !== 'production') {
1477
+ console.error('Functions that are interpolated in css calls will be stringified.\n' + 'If you want to have a css call based on props, create a function that returns a css call like this\n' + 'let dynamicStyle = (props) => css`color: ${props.color}`\n' + 'It can be called directly with props or interpolated in a styled call like this\n' + "let SomeComponent = styled('div')`${dynamicStyle}`");
1154
1478
  }
1155
1479
 
1156
1480
  break;
1157
1481
  }
1158
- } // finalize string values (regular strings and functions interpolated into css calls)
1159
1482
 
1483
+ case 'string':
1484
+ if (process.env.NODE_ENV !== 'production') {
1485
+ var matched = [];
1486
+ var replaced = interpolation.replace(animationRegex, function (match, p1, p2) {
1487
+ var fakeVarName = "animation" + matched.length;
1488
+ matched.push("const " + fakeVarName + " = keyframes`" + p2.replace(/^@keyframes animation-\w+/, '') + "`");
1489
+ return "${" + fakeVarName + "}";
1490
+ });
1491
+
1492
+ if (matched.length) {
1493
+ console.error('`keyframes` output got interpolated into plain string, please wrap it with `css`.\n\n' + 'Instead of doing this:\n\n' + [].concat(matched, ["`" + replaced + "`"]).join('\n') + '\n\nYou should wrap it with `css` like this:\n\n' + ("css`" + replaced + "`"));
1494
+ }
1495
+ }
1160
1496
 
1161
- var asString = interpolation;
1497
+ break;
1498
+ } // finalize string values (regular strings and functions interpolated into css calls)
1162
1499
 
1163
- {
1164
- return asString;
1500
+
1501
+ if (registered == null) {
1502
+ return interpolation;
1165
1503
  }
1504
+
1505
+ var cached = registered[interpolation];
1506
+ return cached !== undefined ? cached : interpolation;
1166
1507
  }
1167
1508
 
1168
1509
  function createStringFromObject(mergedProps, registered, obj) {
@@ -1173,38 +1514,44 @@ function createStringFromObject(mergedProps, registered, obj) {
1173
1514
  string += handleInterpolation(mergedProps, registered, obj[i]) + ";";
1174
1515
  }
1175
1516
  } else {
1176
- for (var key in obj) {
1177
- var value = obj[key];
1517
+ for (var _key in obj) {
1518
+ var value = obj[_key];
1178
1519
 
1179
1520
  if (typeof value !== 'object') {
1180
- var asString = value;
1181
-
1182
- if (isProcessableValue(asString)) {
1183
- string += processStyleName(key) + ":" + processStyleValue(key, asString) + ";";
1521
+ if (registered != null && registered[value] !== undefined) {
1522
+ string += _key + "{" + registered[value] + "}";
1523
+ } else if (isProcessableValue(value)) {
1524
+ string += processStyleName(_key) + ":" + processStyleValue(_key, value) + ";";
1184
1525
  }
1185
1526
  } else {
1527
+ if (_key === 'NO_COMPONENT_SELECTOR' && process.env.NODE_ENV !== 'production') {
1528
+ throw new Error(noComponentSelectorMessage);
1529
+ }
1186
1530
 
1187
- if (Array.isArray(value) && typeof value[0] === 'string' && (registered == null)) {
1531
+ if (Array.isArray(value) && typeof value[0] === 'string' && (registered == null || registered[value[0]] === undefined)) {
1188
1532
  for (var _i = 0; _i < value.length; _i++) {
1189
1533
  if (isProcessableValue(value[_i])) {
1190
- string += processStyleName(key) + ":" + processStyleValue(key, value[_i]) + ";";
1534
+ string += processStyleName(_key) + ":" + processStyleValue(_key, value[_i]) + ";";
1191
1535
  }
1192
1536
  }
1193
1537
  } else {
1194
1538
  var interpolated = handleInterpolation(mergedProps, registered, value);
1195
1539
 
1196
- switch (key) {
1540
+ switch (_key) {
1197
1541
  case 'animation':
1198
1542
  case 'animationName':
1199
1543
  {
1200
- string += processStyleName(key) + ":" + interpolated + ";";
1544
+ string += processStyleName(_key) + ":" + interpolated + ";";
1201
1545
  break;
1202
1546
  }
1203
1547
 
1204
1548
  default:
1205
1549
  {
1550
+ if (process.env.NODE_ENV !== 'production' && _key === 'undefined') {
1551
+ console.error(UNDEFINED_AS_OBJECT_KEY_ERROR);
1552
+ }
1206
1553
 
1207
- string += key + "{" + interpolated + "}";
1554
+ string += _key + "{" + interpolated + "}";
1208
1555
  }
1209
1556
  }
1210
1557
  }
@@ -1216,11 +1563,16 @@ function createStringFromObject(mergedProps, registered, obj) {
1216
1563
  }
1217
1564
 
1218
1565
  var labelPattern = /label:\s*([^\s;\n{]+)\s*(;|$)/g;
1566
+ var sourceMapPattern;
1567
+
1568
+ if (process.env.NODE_ENV !== 'production') {
1569
+ sourceMapPattern = /\/\*#\ssourceMappingURL=data:application\/json;\S+\s+\*\//g;
1570
+ } // this is the cursor for keyframes
1219
1571
  // keyframes are stored on the SerializedStyles object as a linked list
1220
1572
 
1221
1573
 
1222
1574
  var cursor;
1223
- function serializeStyles(args, registered, mergedProps) {
1575
+ var serializeStyles = function serializeStyles(args, registered, mergedProps) {
1224
1576
  if (args.length === 1 && typeof args[0] === 'object' && args[0] !== null && args[0].styles !== undefined) {
1225
1577
  return args[0];
1226
1578
  }
@@ -1234,9 +1586,11 @@ function serializeStyles(args, registered, mergedProps) {
1234
1586
  stringMode = false;
1235
1587
  styles += handleInterpolation(mergedProps, registered, strings);
1236
1588
  } else {
1237
- var asTemplateStringsArr = strings;
1589
+ if (process.env.NODE_ENV !== 'production' && strings[0] === undefined) {
1590
+ console.error(ILLEGAL_ESCAPE_SEQUENCE_ERROR);
1591
+ }
1238
1592
 
1239
- styles += asTemplateStringsArr[0];
1593
+ styles += strings[0];
1240
1594
  } // we start at 1 since we've already handled the first arg
1241
1595
 
1242
1596
 
@@ -1244,45 +1598,69 @@ function serializeStyles(args, registered, mergedProps) {
1244
1598
  styles += handleInterpolation(mergedProps, registered, args[i]);
1245
1599
 
1246
1600
  if (stringMode) {
1247
- var templateStringsArr = strings;
1601
+ if (process.env.NODE_ENV !== 'production' && strings[i] === undefined) {
1602
+ console.error(ILLEGAL_ESCAPE_SEQUENCE_ERROR);
1603
+ }
1248
1604
 
1249
- styles += templateStringsArr[i];
1605
+ styles += strings[i];
1250
1606
  }
1251
1607
  }
1252
1608
 
1609
+ var sourceMap;
1610
+
1611
+ if (process.env.NODE_ENV !== 'production') {
1612
+ styles = styles.replace(sourceMapPattern, function (match) {
1613
+ sourceMap = match;
1614
+ return '';
1615
+ });
1616
+ } // using a global regex with .exec is stateful so lastIndex has to be reset each time
1617
+
1253
1618
 
1254
1619
  labelPattern.lastIndex = 0;
1255
1620
  var identifierName = '';
1256
1621
  var match; // https://esbench.com/bench/5b809c2cf2949800a0f61fb5
1257
1622
 
1258
1623
  while ((match = labelPattern.exec(styles)) !== null) {
1259
- identifierName += '-' + match[1];
1624
+ identifierName += '-' + // $FlowFixMe we know it's not null
1625
+ match[1];
1260
1626
  }
1261
1627
 
1262
1628
  var name = murmur2(styles) + identifierName;
1263
1629
 
1630
+ if (process.env.NODE_ENV !== 'production') {
1631
+ // $FlowFixMe SerializedStyles type doesn't have toString property (and we don't want to add it)
1632
+ return {
1633
+ name: name,
1634
+ styles: styles,
1635
+ map: sourceMap,
1636
+ next: cursor,
1637
+ toString: function toString() {
1638
+ return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop).";
1639
+ }
1640
+ };
1641
+ }
1642
+
1264
1643
  return {
1265
1644
  name: name,
1266
1645
  styles: styles,
1267
1646
  next: cursor
1268
1647
  };
1269
- }
1648
+ };
1270
1649
 
1271
- var isBrowser$1 = typeof document !== 'undefined';
1650
+ var isBrowser$2 = typeof document !== 'undefined';
1272
1651
 
1273
1652
  var syncFallback = function syncFallback(create) {
1274
1653
  return create();
1275
1654
  };
1276
1655
 
1277
1656
  var useInsertionEffect = React['useInsertion' + 'Effect'] ? React['useInsertion' + 'Effect'] : false;
1278
- var useInsertionEffectAlwaysWithSyncFallback = !isBrowser$1 ? syncFallback : useInsertionEffect || syncFallback;
1657
+ var useInsertionEffectAlwaysWithSyncFallback = !isBrowser$2 ? syncFallback : useInsertionEffect || syncFallback;
1658
+ var useInsertionEffectWithLayoutFallback = useInsertionEffect || React.useLayoutEffect;
1279
1659
 
1280
- var isBrowser = typeof document !== 'undefined';
1660
+ var isBrowser$1 = typeof document !== 'undefined';
1661
+ var hasOwnProperty = {}.hasOwnProperty;
1281
1662
 
1282
- /* import { type EmotionCache } from '@emotion/utils' */
1283
- var EmotionCacheContext
1284
- /*: React.Context<EmotionCache | null> */
1285
- = /* #__PURE__ */React.createContext( // we're doing this to avoid preconstruct's dead code elimination in this one case
1663
+ var EmotionCacheContext = /* #__PURE__ */React.createContext( // we're doing this to avoid preconstruct's dead code elimination in this one case
1286
1664
  // because this module is primarily intended for the browser and node
1287
1665
  // but it's also required in react native and similar environments sometimes
1288
1666
  // and we could have a special build just for that
@@ -1292,37 +1670,24 @@ typeof HTMLElement !== 'undefined' ? /* #__PURE__ */createCache({
1292
1670
  key: 'css'
1293
1671
  }) : null);
1294
1672
 
1673
+ if (process.env.NODE_ENV !== 'production') {
1674
+ EmotionCacheContext.displayName = 'EmotionCacheContext';
1675
+ }
1676
+
1295
1677
  EmotionCacheContext.Provider;
1296
1678
 
1297
- var withEmotionCache = function withEmotionCache
1298
- /* <Props, Ref: React.Ref<*>> */
1299
- (func
1300
- /*: (props: Props, cache: EmotionCache, ref: Ref) => React.Node */
1301
- )
1302
- /*: React.AbstractComponent<Props> */
1303
- {
1304
- return /*#__PURE__*/forwardRef(function (props
1305
- /*: Props */
1306
- , ref
1307
- /*: Ref */
1308
- ) {
1679
+ var withEmotionCache = function withEmotionCache(func) {
1680
+ // $FlowFixMe
1681
+ return /*#__PURE__*/forwardRef(function (props, ref) {
1309
1682
  // the cache will never be null in the browser
1310
1683
  var cache = useContext(EmotionCacheContext);
1311
1684
  return func(props, cache, ref);
1312
1685
  });
1313
1686
  };
1314
1687
 
1315
- if (!isBrowser) {
1316
- withEmotionCache = function withEmotionCache
1317
- /* <Props> */
1318
- (func
1319
- /*: (props: Props, cache: EmotionCache) => React.Node */
1320
- )
1321
- /*: React.StatelessFunctionalComponent<Props> */
1322
- {
1323
- return function (props
1324
- /*: Props */
1325
- ) {
1688
+ if (!isBrowser$1) {
1689
+ withEmotionCache = function withEmotionCache(func) {
1690
+ return function (props) {
1326
1691
  var cache = useContext(EmotionCacheContext);
1327
1692
 
1328
1693
  if (cache === null) {
@@ -1346,31 +1711,81 @@ if (!isBrowser) {
1346
1711
 
1347
1712
  var ThemeContext = /* #__PURE__ */React.createContext({});
1348
1713
 
1349
- var hasOwn = {}.hasOwnProperty;
1714
+ if (process.env.NODE_ENV !== 'production') {
1715
+ ThemeContext.displayName = 'EmotionThemeContext';
1716
+ }
1717
+
1718
+ var getLastPart = function getLastPart(functionName) {
1719
+ // The match may be something like 'Object.createEmotionProps' or
1720
+ // 'Loader.prototype.render'
1721
+ var parts = functionName.split('.');
1722
+ return parts[parts.length - 1];
1723
+ };
1724
+
1725
+ var getFunctionNameFromStackTraceLine = function getFunctionNameFromStackTraceLine(line) {
1726
+ // V8
1727
+ var match = /^\s+at\s+([A-Za-z0-9$.]+)\s/.exec(line);
1728
+ if (match) return getLastPart(match[1]); // Safari / Firefox
1729
+
1730
+ match = /^([A-Za-z0-9$.]+)@/.exec(line);
1731
+ if (match) return getLastPart(match[1]);
1732
+ return undefined;
1733
+ };
1734
+
1735
+ var internalReactFunctionNames = /* #__PURE__ */new Set(['renderWithHooks', 'processChild', 'finishClassComponent', 'renderToString']); // These identifiers come from error stacks, so they have to be valid JS
1736
+ // identifiers, thus we only need to replace what is a valid character for JS,
1737
+ // but not for CSS.
1738
+
1739
+ var sanitizeIdentifier = function sanitizeIdentifier(identifier) {
1740
+ return identifier.replace(/\$/g, '-');
1741
+ };
1742
+
1743
+ var getLabelFromStackTrace = function getLabelFromStackTrace(stackTrace) {
1744
+ if (!stackTrace) return undefined;
1745
+ var lines = stackTrace.split('\n');
1746
+
1747
+ for (var i = 0; i < lines.length; i++) {
1748
+ var functionName = getFunctionNameFromStackTraceLine(lines[i]); // The first line of V8 stack traces is just "Error"
1749
+
1750
+ if (!functionName) continue; // If we reach one of these, we have gone too far and should quit
1751
+
1752
+ if (internalReactFunctionNames.has(functionName)) break; // The component name is the first function in the stack that starts with an
1753
+ // uppercase letter
1754
+
1755
+ if (/^[A-Z]/.test(functionName)) return sanitizeIdentifier(functionName);
1756
+ }
1757
+
1758
+ return undefined;
1759
+ };
1350
1760
 
1351
1761
  var typePropName = '__EMOTION_TYPE_PLEASE_DO_NOT_USE__';
1352
- var createEmotionProps = function createEmotionProps(type
1353
- /*: React.ElementType */
1354
- , props
1355
- /*: Object */
1356
- ) {
1762
+ var labelPropName = '__EMOTION_LABEL_PLEASE_DO_NOT_USE__';
1763
+ var createEmotionProps = function createEmotionProps(type, props) {
1764
+ if (process.env.NODE_ENV !== 'production' && typeof props.css === 'string' && // check if there is a css declaration
1765
+ props.css.indexOf(':') !== -1) {
1766
+ throw new Error("Strings are not allowed as css prop values, please wrap it in a css template literal from '@emotion/react' like this: css`" + props.css + "`");
1767
+ }
1357
1768
 
1358
- var newProps
1359
- /*: any */
1360
- = {};
1769
+ var newProps = {};
1361
1770
 
1362
1771
  for (var key in props) {
1363
- if (hasOwn.call(props, key)) {
1772
+ if (hasOwnProperty.call(props, key)) {
1364
1773
  newProps[key] = props[key];
1365
1774
  }
1366
1775
  }
1367
1776
 
1368
- newProps[typePropName] = type; // Runtime labeling is an opt-in feature because:
1777
+ newProps[typePropName] = type; // For performance, only call getLabelFromStackTrace in development and when
1778
+ // the label hasn't already been computed
1779
+
1780
+ if (process.env.NODE_ENV !== 'production' && !!props.css && (typeof props.css !== 'object' || typeof props.css.name !== 'string' || props.css.name.indexOf('-') === -1)) {
1781
+ var label = getLabelFromStackTrace(new Error().stack);
1782
+ if (label) newProps[labelPropName] = label;
1783
+ }
1369
1784
 
1370
1785
  return newProps;
1371
1786
  };
1372
1787
 
1373
- var Insertion = function Insertion(_ref) {
1788
+ var Insertion$1 = function Insertion(_ref) {
1374
1789
  var cache = _ref.cache,
1375
1790
  serialized = _ref.serialized,
1376
1791
  isStringTag = _ref.isStringTag;
@@ -1379,7 +1794,7 @@ var Insertion = function Insertion(_ref) {
1379
1794
  return insertStyles(cache, serialized, isStringTag);
1380
1795
  });
1381
1796
 
1382
- if (!isBrowser && rules !== undefined) {
1797
+ if (!isBrowser$1 && rules !== undefined) {
1383
1798
  var _ref2;
1384
1799
 
1385
1800
  var serializedNames = serialized.name;
@@ -1398,9 +1813,7 @@ var Insertion = function Insertion(_ref) {
1398
1813
  return null;
1399
1814
  };
1400
1815
 
1401
- var Emotion = /* #__PURE__ */withEmotionCache(
1402
- /* <any, any> */
1403
- function (props, cache, ref) {
1816
+ var Emotion = /* #__PURE__ */withEmotionCache(function (props, cache, ref) {
1404
1817
  var cssProp = props.css; // so that using `css` from `emotion` and passing the result to the css prop works
1405
1818
  // not passing the registered cache to serializeStyles because it would
1406
1819
  // make certain babel optimisations not possible
@@ -1421,42 +1834,46 @@ function (props, cache, ref) {
1421
1834
 
1422
1835
  var serialized = serializeStyles(registeredStyles, undefined, React.useContext(ThemeContext));
1423
1836
 
1837
+ if (process.env.NODE_ENV !== 'production' && serialized.name.indexOf('-') === -1) {
1838
+ var labelFromStack = props[labelPropName];
1839
+
1840
+ if (labelFromStack) {
1841
+ serialized = serializeStyles([serialized, 'label:' + labelFromStack + ';']);
1842
+ }
1843
+ }
1844
+
1424
1845
  className += cache.key + "-" + serialized.name;
1425
1846
  var newProps = {};
1426
1847
 
1427
1848
  for (var key in props) {
1428
- if (hasOwn.call(props, key) && key !== 'css' && key !== typePropName && (true )) {
1849
+ if (hasOwnProperty.call(props, key) && key !== 'css' && key !== typePropName && (process.env.NODE_ENV === 'production' || key !== labelPropName)) {
1429
1850
  newProps[key] = props[key];
1430
1851
  }
1431
1852
  }
1432
1853
 
1854
+ newProps.ref = ref;
1433
1855
  newProps.className = className;
1434
-
1435
- if (ref) {
1436
- newProps.ref = ref;
1437
- }
1438
-
1439
- return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Insertion, {
1856
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Insertion$1, {
1440
1857
  cache: cache,
1441
1858
  serialized: serialized,
1442
1859
  isStringTag: typeof WrappedComponent === 'string'
1443
1860
  }), /*#__PURE__*/React.createElement(WrappedComponent, newProps));
1444
1861
  });
1445
1862
 
1863
+ if (process.env.NODE_ENV !== 'production') {
1864
+ Emotion.displayName = 'EmotionCssPropInternal';
1865
+ }
1866
+
1446
1867
  var Emotion$1 = Emotion;
1447
1868
 
1448
- var jsx
1449
- /*: typeof React.createElement */
1450
- = function jsx
1451
- /*: typeof React.createElement */
1452
- (type
1453
- /*: React.ElementType */
1454
- , props
1455
- /*: Object */
1456
- ) {
1869
+ var pkg = {
1870
+ version: "11.11.1"};
1871
+
1872
+ var jsx = function jsx(type, props) {
1457
1873
  var args = arguments;
1458
1874
 
1459
- if (props == null || !hasOwn.call(props, 'css')) {
1875
+ if (props == null || !hasOwnProperty.call(props, 'css')) {
1876
+ // $FlowFixMe
1460
1877
  return React.createElement.apply(undefined, args);
1461
1878
  }
1462
1879
 
@@ -1467,16 +1884,123 @@ var jsx
1467
1884
 
1468
1885
  for (var i = 2; i < argsLength; i++) {
1469
1886
  createElementArgArray[i] = args[i];
1470
- }
1887
+ } // $FlowFixMe
1888
+
1471
1889
 
1472
1890
  return React.createElement.apply(null, createElementArgArray);
1473
1891
  };
1474
1892
 
1475
- /* import type { Interpolation, SerializedStyles } from '@emotion/utils' */
1893
+ var warnedAboutCssPropForGlobal = false; // maintain place over rerenders.
1894
+ // initial render from browser, insertBefore context.sheet.tags[0] or if a style hasn't been inserted there yet, appendChild
1895
+ // initial client-side render from SSR, use place of hydrating tag
1896
+
1897
+ var Global = /* #__PURE__ */withEmotionCache(function (props, cache) {
1898
+ if (process.env.NODE_ENV !== 'production' && !warnedAboutCssPropForGlobal && ( // check for className as well since the user is
1899
+ // probably using the custom createElement which
1900
+ // means it will be turned into a className prop
1901
+ // $FlowFixMe I don't really want to add it to the type since it shouldn't be used
1902
+ props.className || props.css)) {
1903
+ console.error("It looks like you're using the css prop on Global, did you mean to use the styles prop instead?");
1904
+ warnedAboutCssPropForGlobal = true;
1905
+ }
1906
+
1907
+ var styles = props.styles;
1908
+ var serialized = serializeStyles([styles], undefined, React.useContext(ThemeContext));
1909
+
1910
+ if (!isBrowser$1) {
1911
+ var _ref;
1912
+
1913
+ var serializedNames = serialized.name;
1914
+ var serializedStyles = serialized.styles;
1915
+ var next = serialized.next;
1916
+
1917
+ while (next !== undefined) {
1918
+ serializedNames += ' ' + next.name;
1919
+ serializedStyles += next.styles;
1920
+ next = next.next;
1921
+ }
1922
+
1923
+ var shouldCache = cache.compat === true;
1924
+ var rules = cache.insert("", {
1925
+ name: serializedNames,
1926
+ styles: serializedStyles
1927
+ }, cache.sheet, shouldCache);
1928
+
1929
+ if (shouldCache) {
1930
+ return null;
1931
+ }
1932
+
1933
+ return /*#__PURE__*/React.createElement("style", (_ref = {}, _ref["data-emotion"] = cache.key + "-global " + serializedNames, _ref.dangerouslySetInnerHTML = {
1934
+ __html: rules
1935
+ }, _ref.nonce = cache.sheet.nonce, _ref));
1936
+ } // yes, i know these hooks are used conditionally
1937
+ // but it is based on a constant that will never change at runtime
1938
+ // it's effectively like having two implementations and switching them out
1939
+ // so it's not actually breaking anything
1940
+
1941
+
1942
+ var sheetRef = React.useRef();
1943
+ useInsertionEffectWithLayoutFallback(function () {
1944
+ var key = cache.key + "-global"; // use case of https://github.com/emotion-js/emotion/issues/2675
1945
+
1946
+ var sheet = new cache.sheet.constructor({
1947
+ key: key,
1948
+ nonce: cache.sheet.nonce,
1949
+ container: cache.sheet.container,
1950
+ speedy: cache.sheet.isSpeedy
1951
+ });
1952
+ var rehydrating = false; // $FlowFixMe
1953
+
1954
+ var node = document.querySelector("style[data-emotion=\"" + key + " " + serialized.name + "\"]");
1955
+
1956
+ if (cache.sheet.tags.length) {
1957
+ sheet.before = cache.sheet.tags[0];
1958
+ }
1959
+
1960
+ if (node !== null) {
1961
+ rehydrating = true; // clear the hash so this node won't be recognizable as rehydratable by other <Global/>s
1962
+
1963
+ node.setAttribute('data-emotion', key);
1964
+ sheet.hydrate([node]);
1965
+ }
1966
+
1967
+ sheetRef.current = [sheet, rehydrating];
1968
+ return function () {
1969
+ sheet.flush();
1970
+ };
1971
+ }, [cache]);
1972
+ useInsertionEffectWithLayoutFallback(function () {
1973
+ var sheetRefCurrent = sheetRef.current;
1974
+ var sheet = sheetRefCurrent[0],
1975
+ rehydrating = sheetRefCurrent[1];
1976
+
1977
+ if (rehydrating) {
1978
+ sheetRefCurrent[1] = false;
1979
+ return;
1980
+ }
1981
+
1982
+ if (serialized.next !== undefined) {
1983
+ // insert keyframes
1984
+ insertStyles(cache, serialized.next, true);
1985
+ }
1986
+
1987
+ if (sheet.tags.length) {
1988
+ // if this doesn't exist then it will be null so the style element will be appended
1989
+ var element = sheet.tags[sheet.tags.length - 1].nextElementSibling;
1990
+ sheet.before = element;
1991
+ sheet.flush();
1992
+ }
1993
+
1994
+ cache.insert("", serialized, sheet, false);
1995
+ }, [cache, serialized.name]);
1996
+ return null;
1997
+ });
1998
+
1999
+ if (process.env.NODE_ENV !== 'production') {
2000
+ Global.displayName = 'EmotionGlobal';
2001
+ }
1476
2002
 
1477
- function css$2()
1478
- /*: SerializedStyles */
1479
- {
2003
+ function css$2() {
1480
2004
  for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
1481
2005
  args[_key] = arguments[_key];
1482
2006
  }
@@ -1484,20 +2008,10 @@ function css$2()
1484
2008
  return serializeStyles(args);
1485
2009
  }
1486
2010
 
1487
- /*
1488
- type Keyframes = {|
1489
- name: string,
1490
- styles: string,
1491
- anim: 1,
1492
- toString: () => string
1493
- |} & string
1494
- */
1495
-
1496
- var keyframes = function
1497
- /*: Keyframes */
1498
- keyframes() {
2011
+ var keyframes = function keyframes() {
1499
2012
  var insertable = css$2.apply(void 0, arguments);
1500
- var name = "animation-" + insertable.name;
2013
+ var name = "animation-" + insertable.name; // $FlowFixMe
2014
+
1501
2015
  return {
1502
2016
  name: name,
1503
2017
  styles: "@keyframes " + name + "{" + insertable.styles + "}",
@@ -1508,6 +2022,169 @@ keyframes() {
1508
2022
  };
1509
2023
  };
1510
2024
 
2025
+ var classnames = function classnames(args) {
2026
+ var len = args.length;
2027
+ var i = 0;
2028
+ var cls = '';
2029
+
2030
+ for (; i < len; i++) {
2031
+ var arg = args[i];
2032
+ if (arg == null) continue;
2033
+ var toAdd = void 0;
2034
+
2035
+ switch (typeof arg) {
2036
+ case 'boolean':
2037
+ break;
2038
+
2039
+ case 'object':
2040
+ {
2041
+ if (Array.isArray(arg)) {
2042
+ toAdd = classnames(arg);
2043
+ } else {
2044
+ if (process.env.NODE_ENV !== 'production' && arg.styles !== undefined && arg.name !== undefined) {
2045
+ console.error('You have passed styles created with `css` from `@emotion/react` package to the `cx`.\n' + '`cx` is meant to compose class names (strings) so you should convert those styles to a class name by passing them to the `css` received from <ClassNames/> component.');
2046
+ }
2047
+
2048
+ toAdd = '';
2049
+
2050
+ for (var k in arg) {
2051
+ if (arg[k] && k) {
2052
+ toAdd && (toAdd += ' ');
2053
+ toAdd += k;
2054
+ }
2055
+ }
2056
+ }
2057
+
2058
+ break;
2059
+ }
2060
+
2061
+ default:
2062
+ {
2063
+ toAdd = arg;
2064
+ }
2065
+ }
2066
+
2067
+ if (toAdd) {
2068
+ cls && (cls += ' ');
2069
+ cls += toAdd;
2070
+ }
2071
+ }
2072
+
2073
+ return cls;
2074
+ };
2075
+
2076
+ function merge(registered, css, className) {
2077
+ var registeredStyles = [];
2078
+ var rawClassName = getRegisteredStyles(registered, registeredStyles, className);
2079
+
2080
+ if (registeredStyles.length < 2) {
2081
+ return className;
2082
+ }
2083
+
2084
+ return rawClassName + css(registeredStyles);
2085
+ }
2086
+
2087
+ var Insertion = function Insertion(_ref) {
2088
+ var cache = _ref.cache,
2089
+ serializedArr = _ref.serializedArr;
2090
+ var rules = useInsertionEffectAlwaysWithSyncFallback(function () {
2091
+ var rules = '';
2092
+
2093
+ for (var i = 0; i < serializedArr.length; i++) {
2094
+ var res = insertStyles(cache, serializedArr[i], false);
2095
+
2096
+ if (!isBrowser$1 && res !== undefined) {
2097
+ rules += res;
2098
+ }
2099
+ }
2100
+
2101
+ if (!isBrowser$1) {
2102
+ return rules;
2103
+ }
2104
+ });
2105
+
2106
+ if (!isBrowser$1 && rules.length !== 0) {
2107
+ var _ref2;
2108
+
2109
+ return /*#__PURE__*/React.createElement("style", (_ref2 = {}, _ref2["data-emotion"] = cache.key + " " + serializedArr.map(function (serialized) {
2110
+ return serialized.name;
2111
+ }).join(' '), _ref2.dangerouslySetInnerHTML = {
2112
+ __html: rules
2113
+ }, _ref2.nonce = cache.sheet.nonce, _ref2));
2114
+ }
2115
+
2116
+ return null;
2117
+ };
2118
+
2119
+ var ClassNames = /* #__PURE__ */withEmotionCache(function (props, cache) {
2120
+ var hasRendered = false;
2121
+ var serializedArr = [];
2122
+
2123
+ var css = function css() {
2124
+ if (hasRendered && process.env.NODE_ENV !== 'production') {
2125
+ throw new Error('css can only be used during render');
2126
+ }
2127
+
2128
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
2129
+ args[_key] = arguments[_key];
2130
+ }
2131
+
2132
+ var serialized = serializeStyles(args, cache.registered);
2133
+ serializedArr.push(serialized); // registration has to happen here as the result of this might get consumed by `cx`
2134
+
2135
+ registerStyles(cache, serialized, false);
2136
+ return cache.key + "-" + serialized.name;
2137
+ };
2138
+
2139
+ var cx = function cx() {
2140
+ if (hasRendered && process.env.NODE_ENV !== 'production') {
2141
+ throw new Error('cx can only be used during render');
2142
+ }
2143
+
2144
+ for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
2145
+ args[_key2] = arguments[_key2];
2146
+ }
2147
+
2148
+ return merge(cache.registered, css, classnames(args));
2149
+ };
2150
+
2151
+ var content = {
2152
+ css: css,
2153
+ cx: cx,
2154
+ theme: React.useContext(ThemeContext)
2155
+ };
2156
+ var ele = props.children(content);
2157
+ hasRendered = true;
2158
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Insertion, {
2159
+ cache: cache,
2160
+ serializedArr: serializedArr
2161
+ }), ele);
2162
+ });
2163
+
2164
+ if (process.env.NODE_ENV !== 'production') {
2165
+ ClassNames.displayName = 'EmotionClassNames';
2166
+ }
2167
+
2168
+ if (process.env.NODE_ENV !== 'production') {
2169
+ var isBrowser = typeof document !== 'undefined'; // #1727, #2905 for some reason Jest and Vitest evaluate modules twice if some consuming module gets mocked
2170
+
2171
+ var isTestEnv = typeof jest !== 'undefined' || typeof vi !== 'undefined';
2172
+
2173
+ if (isBrowser && !isTestEnv) {
2174
+ // globalThis has wide browser support - https://caniuse.com/?search=globalThis, Node.js 12 and later
2175
+ var globalContext = // $FlowIgnore
2176
+ typeof globalThis !== 'undefined' ? globalThis // eslint-disable-line no-undef
2177
+ : isBrowser ? window : global;
2178
+ var globalKey = "__EMOTION_REACT_" + pkg.version.split('.')[0] + "__";
2179
+
2180
+ if (globalContext[globalKey]) {
2181
+ console.warn('You are loading @emotion/react when it is already loaded. Running ' + 'multiple instances may cause problems. This can happen if multiple ' + 'versions are used, or if multiple builds of the same version are ' + 'used.');
2182
+ }
2183
+
2184
+ globalContext[globalKey] = true;
2185
+ }
2186
+ }
2187
+
1511
2188
  function _taggedTemplateLiteral(strings, raw) {
1512
2189
  if (!raw) {
1513
2190
  raw = strings.slice(0);
@@ -1519,6 +2196,16 @@ function _taggedTemplateLiteral(strings, raw) {
1519
2196
  }));
1520
2197
  }
1521
2198
 
2199
+ function rectToClientRect(rect) {
2200
+ return {
2201
+ ...rect,
2202
+ top: rect.y,
2203
+ left: rect.x,
2204
+ right: rect.x + rect.width,
2205
+ bottom: rect.y + rect.height
2206
+ };
2207
+ }
2208
+
1522
2209
  function getWindow(node) {
1523
2210
  var _node$ownerDocument;
1524
2211
  return ((_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;