@thunderid/react 0.12.0 → 0.13.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 (356) hide show
  1. package/dist/cjs/components/actions/SignInButton/BaseSignInButton.cjs +2 -3
  2. package/dist/cjs/components/actions/SignInButton/BaseSignInButton.cjs.map +1 -1
  3. package/dist/cjs/components/actions/SignOutButton/BaseSignOutButton.cjs +2 -3
  4. package/dist/cjs/components/actions/SignOutButton/BaseSignOutButton.cjs.map +1 -1
  5. package/dist/cjs/components/actions/SignUpButton/BaseSignUpButton.cjs +2 -3
  6. package/dist/cjs/components/actions/SignUpButton/BaseSignUpButton.cjs.map +1 -1
  7. package/dist/cjs/components/adapters/Consent.cjs +34 -27
  8. package/dist/cjs/components/adapters/Consent.cjs.map +1 -1
  9. package/dist/cjs/components/adapters/ConsentCheckboxList.cjs +7 -8
  10. package/dist/cjs/components/adapters/ConsentCheckboxList.cjs.map +1 -1
  11. package/dist/cjs/components/adapters/ConsentCheckboxList.styles.cjs +8 -9
  12. package/dist/cjs/components/adapters/ConsentCheckboxList.styles.cjs.map +1 -1
  13. package/dist/cjs/components/adapters/ImageComponent.cjs +13 -9
  14. package/dist/cjs/components/adapters/ImageComponent.cjs.map +1 -1
  15. package/dist/cjs/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.cjs +3 -4
  16. package/dist/cjs/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.cjs.map +1 -1
  17. package/dist/cjs/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.styles.cjs +11 -12
  18. package/dist/cjs/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.styles.cjs.map +1 -1
  19. package/dist/cjs/components/presentation/UserDropdown/BaseUserDropdown.cjs +12 -16
  20. package/dist/cjs/components/presentation/UserDropdown/BaseUserDropdown.cjs.map +1 -1
  21. package/dist/cjs/components/presentation/UserDropdown/BaseUserDropdown.styles.cjs +18 -15
  22. package/dist/cjs/components/presentation/UserDropdown/BaseUserDropdown.styles.cjs.map +1 -1
  23. package/dist/cjs/components/presentation/UserProfile/BaseUserProfile.cjs +5 -6
  24. package/dist/cjs/components/presentation/UserProfile/BaseUserProfile.cjs.map +1 -1
  25. package/dist/cjs/components/presentation/UserProfile/BaseUserProfile.styles.cjs +25 -26
  26. package/dist/cjs/components/presentation/UserProfile/BaseUserProfile.styles.cjs.map +1 -1
  27. package/dist/cjs/components/presentation/auth/AcceptInvite/BaseAcceptInvite.cjs +10 -31
  28. package/dist/cjs/components/presentation/auth/AcceptInvite/BaseAcceptInvite.cjs.map +1 -1
  29. package/dist/cjs/components/presentation/auth/AcceptInvite/BaseAcceptInvite.styles.cjs +41 -9
  30. package/dist/cjs/components/presentation/auth/AcceptInvite/BaseAcceptInvite.styles.cjs.map +1 -1
  31. package/dist/cjs/components/presentation/auth/AuthOptionFactory.cjs +75 -71
  32. package/dist/cjs/components/presentation/auth/AuthOptionFactory.cjs.map +1 -1
  33. package/dist/cjs/components/presentation/auth/InviteUser/BaseInviteUser.cjs +9 -22
  34. package/dist/cjs/components/presentation/auth/InviteUser/BaseInviteUser.cjs.map +1 -1
  35. package/dist/cjs/components/presentation/auth/InviteUser/BaseInviteUser.styles.cjs +22 -9
  36. package/dist/cjs/components/presentation/auth/InviteUser/BaseInviteUser.styles.cjs.map +1 -1
  37. package/dist/cjs/components/presentation/auth/Recovery/BaseRecovery.cjs +11 -12
  38. package/dist/cjs/components/presentation/auth/Recovery/BaseRecovery.cjs.map +1 -1
  39. package/dist/cjs/components/presentation/auth/SignIn/BaseSignIn.cjs +11 -16
  40. package/dist/cjs/components/presentation/auth/SignIn/BaseSignIn.cjs.map +1 -1
  41. package/dist/cjs/components/presentation/auth/SignIn/BaseSignIn.styles.cjs +32 -27
  42. package/dist/cjs/components/presentation/auth/SignIn/BaseSignIn.styles.cjs.map +1 -1
  43. package/dist/cjs/components/presentation/auth/SignUp/BaseSignUp.cjs +11 -12
  44. package/dist/cjs/components/presentation/auth/SignUp/BaseSignUp.cjs.map +1 -1
  45. package/dist/cjs/components/presentation/auth/SignUp/BaseSignUp.styles.cjs +25 -26
  46. package/dist/cjs/components/presentation/auth/SignUp/BaseSignUp.styles.cjs.map +1 -1
  47. package/dist/cjs/components/primitives/AffixedField/AffixedField.cjs +6 -7
  48. package/dist/cjs/components/primitives/AffixedField/AffixedField.cjs.map +1 -1
  49. package/dist/cjs/components/primitives/AffixedField/AffixedField.styles.cjs +9 -10
  50. package/dist/cjs/components/primitives/AffixedField/AffixedField.styles.cjs.map +1 -1
  51. package/dist/cjs/components/primitives/Alert/Alert.cjs +6 -7
  52. package/dist/cjs/components/primitives/Alert/Alert.cjs.map +1 -1
  53. package/dist/cjs/components/primitives/Alert/Alert.styles.cjs +10 -11
  54. package/dist/cjs/components/primitives/Alert/Alert.styles.cjs.map +1 -1
  55. package/dist/cjs/components/primitives/Avatar/Avatar.cjs +5 -6
  56. package/dist/cjs/components/primitives/Avatar/Avatar.cjs.map +1 -1
  57. package/dist/cjs/components/primitives/Avatar/Avatar.styles.cjs +7 -8
  58. package/dist/cjs/components/primitives/Avatar/Avatar.styles.cjs.map +1 -1
  59. package/dist/cjs/components/primitives/Button/Button.cjs +8 -12
  60. package/dist/cjs/components/primitives/Button/Button.cjs.map +1 -1
  61. package/dist/cjs/components/primitives/Button/Button.styles.cjs +23 -24
  62. package/dist/cjs/components/primitives/Button/Button.styles.cjs.map +1 -1
  63. package/dist/cjs/components/primitives/Card/Card.cjs +8 -9
  64. package/dist/cjs/components/primitives/Card/Card.cjs.map +1 -1
  65. package/dist/cjs/components/primitives/Card/Card.styles.cjs +12 -13
  66. package/dist/cjs/components/primitives/Card/Card.styles.cjs.map +1 -1
  67. package/dist/cjs/components/primitives/Checkbox/Checkbox.cjs +5 -6
  68. package/dist/cjs/components/primitives/Checkbox/Checkbox.cjs.map +1 -1
  69. package/dist/cjs/components/primitives/Checkbox/Checkbox.styles.cjs +7 -8
  70. package/dist/cjs/components/primitives/Checkbox/Checkbox.styles.cjs.map +1 -1
  71. package/dist/cjs/components/primitives/CopyableText/CopyableText.styles.cjs +6 -7
  72. package/dist/cjs/components/primitives/CopyableText/CopyableText.styles.cjs.map +1 -1
  73. package/dist/cjs/components/primitives/DatePicker/DatePicker.cjs +4 -5
  74. package/dist/cjs/components/primitives/DatePicker/DatePicker.cjs.map +1 -1
  75. package/dist/cjs/components/primitives/DatePicker/DatePicker.styles.cjs +5 -6
  76. package/dist/cjs/components/primitives/DatePicker/DatePicker.styles.cjs.map +1 -1
  77. package/dist/cjs/components/primitives/Dialog/Dialog.cjs +7 -8
  78. package/dist/cjs/components/primitives/Dialog/Dialog.cjs.map +1 -1
  79. package/dist/cjs/components/primitives/Dialog/Dialog.styles.cjs +8 -9
  80. package/dist/cjs/components/primitives/Dialog/Dialog.styles.cjs.map +1 -1
  81. package/dist/cjs/components/primitives/Divider/Divider.cjs +7 -8
  82. package/dist/cjs/components/primitives/Divider/Divider.cjs.map +1 -1
  83. package/dist/cjs/components/primitives/Divider/Divider.styles.cjs +7 -8
  84. package/dist/cjs/components/primitives/Divider/Divider.styles.cjs.map +1 -1
  85. package/dist/cjs/components/primitives/FormControl/FormControl.cjs +3 -4
  86. package/dist/cjs/components/primitives/FormControl/FormControl.cjs.map +1 -1
  87. package/dist/cjs/components/primitives/FormControl/FormControl.styles.cjs +4 -5
  88. package/dist/cjs/components/primitives/FormControl/FormControl.styles.cjs.map +1 -1
  89. package/dist/cjs/components/primitives/InputLabel/InputLabel.cjs +3 -4
  90. package/dist/cjs/components/primitives/InputLabel/InputLabel.cjs.map +1 -1
  91. package/dist/cjs/components/primitives/InputLabel/InputLabel.styles.cjs +6 -7
  92. package/dist/cjs/components/primitives/InputLabel/InputLabel.styles.cjs.map +1 -1
  93. package/dist/cjs/components/primitives/KeyValueInput/KeyValueInput.cjs +19 -20
  94. package/dist/cjs/components/primitives/KeyValueInput/KeyValueInput.cjs.map +1 -1
  95. package/dist/cjs/components/primitives/KeyValueInput/KeyValueInput.styles.cjs +16 -17
  96. package/dist/cjs/components/primitives/KeyValueInput/KeyValueInput.styles.cjs.map +1 -1
  97. package/dist/cjs/components/primitives/Logo/Logo.cjs +3 -4
  98. package/dist/cjs/components/primitives/Logo/Logo.cjs.map +1 -1
  99. package/dist/cjs/components/primitives/Logo/Logo.styles.cjs +9 -10
  100. package/dist/cjs/components/primitives/Logo/Logo.styles.cjs.map +1 -1
  101. package/dist/cjs/components/primitives/MultiInput/MultiInput.cjs +11 -12
  102. package/dist/cjs/components/primitives/MultiInput/MultiInput.cjs.map +1 -1
  103. package/dist/cjs/components/primitives/MultiInput/MultiInput.styles.cjs +10 -11
  104. package/dist/cjs/components/primitives/MultiInput/MultiInput.styles.cjs.map +1 -1
  105. package/dist/cjs/components/primitives/OtpField/OtpField.cjs +4 -5
  106. package/dist/cjs/components/primitives/OtpField/OtpField.cjs.map +1 -1
  107. package/dist/cjs/components/primitives/OtpField/OtpField.styles.cjs +5 -6
  108. package/dist/cjs/components/primitives/OtpField/OtpField.styles.cjs.map +1 -1
  109. package/dist/cjs/components/primitives/PasswordField/PasswordField.cjs +3 -4
  110. package/dist/cjs/components/primitives/PasswordField/PasswordField.cjs.map +1 -1
  111. package/dist/cjs/components/primitives/PasswordField/PasswordField.styles.cjs +4 -5
  112. package/dist/cjs/components/primitives/PasswordField/PasswordField.styles.cjs.map +1 -1
  113. package/dist/cjs/components/primitives/Select/Select.cjs +3 -4
  114. package/dist/cjs/components/primitives/Select/Select.cjs.map +1 -1
  115. package/dist/cjs/components/primitives/Select/Select.styles.cjs +5 -6
  116. package/dist/cjs/components/primitives/Select/Select.styles.cjs.map +1 -1
  117. package/dist/cjs/components/primitives/Spinner/Spinner.cjs +4 -6
  118. package/dist/cjs/components/primitives/Spinner/Spinner.cjs.map +1 -1
  119. package/dist/cjs/components/primitives/Spinner/Spinner.styles.cjs +20 -12
  120. package/dist/cjs/components/primitives/Spinner/Spinner.styles.cjs.map +1 -1
  121. package/dist/cjs/components/primitives/TextField/TextField.cjs +6 -7
  122. package/dist/cjs/components/primitives/TextField/TextField.cjs.map +1 -1
  123. package/dist/cjs/components/primitives/TextField/TextField.styles.cjs +8 -9
  124. package/dist/cjs/components/primitives/TextField/TextField.styles.cjs.map +1 -1
  125. package/dist/cjs/components/primitives/Toggle/Toggle.cjs +7 -8
  126. package/dist/cjs/components/primitives/Toggle/Toggle.cjs.map +1 -1
  127. package/dist/cjs/components/primitives/Toggle/Toggle.styles.cjs +7 -8
  128. package/dist/cjs/components/primitives/Toggle/Toggle.styles.cjs.map +1 -1
  129. package/dist/cjs/components/primitives/Tooltip/Tooltip.cjs +4 -5
  130. package/dist/cjs/components/primitives/Tooltip/Tooltip.cjs.map +1 -1
  131. package/dist/cjs/components/primitives/Tooltip/Tooltip.styles.cjs +13 -14
  132. package/dist/cjs/components/primitives/Tooltip/Tooltip.styles.cjs.map +1 -1
  133. package/dist/cjs/components/primitives/Typography/Typography.cjs +2 -3
  134. package/dist/cjs/components/primitives/Typography/Typography.cjs.map +1 -1
  135. package/dist/cjs/components/primitives/Typography/Typography.styles.cjs +18 -19
  136. package/dist/cjs/components/primitives/Typography/Typography.styles.cjs.map +1 -1
  137. package/dist/cjs/contexts/ThunderID/ThunderIDProvider.cjs +4 -1
  138. package/dist/cjs/contexts/ThunderID/ThunderIDProvider.cjs.map +1 -1
  139. package/dist/cjs/styles/emotion.cjs +64 -0
  140. package/dist/cjs/styles/emotion.cjs.map +1 -0
  141. package/dist/components/actions/SignInButton/BaseSignInButton.d.ts.map +1 -1
  142. package/dist/components/actions/SignInButton/BaseSignInButton.js +1 -1
  143. package/dist/components/actions/SignInButton/BaseSignInButton.js.map +1 -1
  144. package/dist/components/actions/SignOutButton/BaseSignOutButton.d.ts.map +1 -1
  145. package/dist/components/actions/SignOutButton/BaseSignOutButton.js +1 -1
  146. package/dist/components/actions/SignOutButton/BaseSignOutButton.js.map +1 -1
  147. package/dist/components/actions/SignUpButton/BaseSignUpButton.d.ts.map +1 -1
  148. package/dist/components/actions/SignUpButton/BaseSignUpButton.js +1 -1
  149. package/dist/components/actions/SignUpButton/BaseSignUpButton.js.map +1 -1
  150. package/dist/components/adapters/Consent.d.ts.map +1 -1
  151. package/dist/components/adapters/Consent.js +34 -27
  152. package/dist/components/adapters/Consent.js.map +1 -1
  153. package/dist/components/adapters/ConsentCheckboxList.d.ts.map +1 -1
  154. package/dist/components/adapters/ConsentCheckboxList.js +1 -1
  155. package/dist/components/adapters/ConsentCheckboxList.js.map +1 -1
  156. package/dist/components/adapters/ConsentCheckboxList.styles.d.ts.map +1 -1
  157. package/dist/components/adapters/ConsentCheckboxList.styles.js +1 -1
  158. package/dist/components/adapters/ConsentCheckboxList.styles.js.map +1 -1
  159. package/dist/components/adapters/ImageComponent.d.ts.map +1 -1
  160. package/dist/components/adapters/ImageComponent.js +13 -9
  161. package/dist/components/adapters/ImageComponent.js.map +1 -1
  162. package/dist/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.d.ts.map +1 -1
  163. package/dist/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.js +1 -1
  164. package/dist/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.js.map +1 -1
  165. package/dist/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.styles.d.ts.map +1 -1
  166. package/dist/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.styles.js +1 -1
  167. package/dist/components/presentation/LanguageSwitcher/BaseLanguageSwitcher.styles.js.map +1 -1
  168. package/dist/components/presentation/UserDropdown/BaseUserDropdown.d.ts.map +1 -1
  169. package/dist/components/presentation/UserDropdown/BaseUserDropdown.js +5 -8
  170. package/dist/components/presentation/UserDropdown/BaseUserDropdown.js.map +1 -1
  171. package/dist/components/presentation/UserDropdown/BaseUserDropdown.styles.d.ts.map +1 -1
  172. package/dist/components/presentation/UserDropdown/BaseUserDropdown.styles.js +5 -1
  173. package/dist/components/presentation/UserDropdown/BaseUserDropdown.styles.js.map +1 -1
  174. package/dist/components/presentation/UserProfile/BaseUserProfile.d.ts.map +1 -1
  175. package/dist/components/presentation/UserProfile/BaseUserProfile.js +1 -1
  176. package/dist/components/presentation/UserProfile/BaseUserProfile.js.map +1 -1
  177. package/dist/components/presentation/UserProfile/BaseUserProfile.styles.d.ts.map +1 -1
  178. package/dist/components/presentation/UserProfile/BaseUserProfile.styles.js +1 -1
  179. package/dist/components/presentation/UserProfile/BaseUserProfile.styles.js.map +1 -1
  180. package/dist/components/presentation/auth/AcceptInvite/BaseAcceptInvite.d.ts.map +1 -1
  181. package/dist/components/presentation/auth/AcceptInvite/BaseAcceptInvite.js +7 -27
  182. package/dist/components/presentation/auth/AcceptInvite/BaseAcceptInvite.js.map +1 -1
  183. package/dist/components/presentation/auth/AcceptInvite/BaseAcceptInvite.styles.d.ts.map +1 -1
  184. package/dist/components/presentation/auth/AcceptInvite/BaseAcceptInvite.styles.js +38 -5
  185. package/dist/components/presentation/auth/AcceptInvite/BaseAcceptInvite.styles.js.map +1 -1
  186. package/dist/components/presentation/auth/AuthOptionFactory.d.ts.map +1 -1
  187. package/dist/components/presentation/auth/AuthOptionFactory.js +68 -63
  188. package/dist/components/presentation/auth/AuthOptionFactory.js.map +1 -1
  189. package/dist/components/presentation/auth/InviteUser/BaseInviteUser.d.ts.map +1 -1
  190. package/dist/components/presentation/auth/InviteUser/BaseInviteUser.js +5 -17
  191. package/dist/components/presentation/auth/InviteUser/BaseInviteUser.js.map +1 -1
  192. package/dist/components/presentation/auth/InviteUser/BaseInviteUser.styles.d.ts.map +1 -1
  193. package/dist/components/presentation/auth/InviteUser/BaseInviteUser.styles.js +19 -5
  194. package/dist/components/presentation/auth/InviteUser/BaseInviteUser.styles.js.map +1 -1
  195. package/dist/components/presentation/auth/Recovery/BaseRecovery.d.ts.map +1 -1
  196. package/dist/components/presentation/auth/Recovery/BaseRecovery.js +1 -1
  197. package/dist/components/presentation/auth/Recovery/BaseRecovery.js.map +1 -1
  198. package/dist/components/presentation/auth/SignIn/BaseSignIn.d.ts.map +1 -1
  199. package/dist/components/presentation/auth/SignIn/BaseSignIn.js +2 -6
  200. package/dist/components/presentation/auth/SignIn/BaseSignIn.js.map +1 -1
  201. package/dist/components/presentation/auth/SignIn/BaseSignIn.styles.d.ts.map +1 -1
  202. package/dist/components/presentation/auth/SignIn/BaseSignIn.styles.js +7 -1
  203. package/dist/components/presentation/auth/SignIn/BaseSignIn.styles.js.map +1 -1
  204. package/dist/components/presentation/auth/SignUp/BaseSignUp.d.ts.map +1 -1
  205. package/dist/components/presentation/auth/SignUp/BaseSignUp.js +1 -1
  206. package/dist/components/presentation/auth/SignUp/BaseSignUp.js.map +1 -1
  207. package/dist/components/presentation/auth/SignUp/BaseSignUp.styles.d.ts.map +1 -1
  208. package/dist/components/presentation/auth/SignUp/BaseSignUp.styles.js +1 -1
  209. package/dist/components/presentation/auth/SignUp/BaseSignUp.styles.js.map +1 -1
  210. package/dist/components/primitives/AffixedField/AffixedField.d.ts.map +1 -1
  211. package/dist/components/primitives/AffixedField/AffixedField.js +1 -1
  212. package/dist/components/primitives/AffixedField/AffixedField.js.map +1 -1
  213. package/dist/components/primitives/AffixedField/AffixedField.styles.d.ts.map +1 -1
  214. package/dist/components/primitives/AffixedField/AffixedField.styles.js +1 -1
  215. package/dist/components/primitives/AffixedField/AffixedField.styles.js.map +1 -1
  216. package/dist/components/primitives/Alert/Alert.d.ts.map +1 -1
  217. package/dist/components/primitives/Alert/Alert.js +1 -1
  218. package/dist/components/primitives/Alert/Alert.js.map +1 -1
  219. package/dist/components/primitives/Alert/Alert.styles.d.ts.map +1 -1
  220. package/dist/components/primitives/Alert/Alert.styles.js +1 -1
  221. package/dist/components/primitives/Alert/Alert.styles.js.map +1 -1
  222. package/dist/components/primitives/Avatar/Avatar.d.ts.map +1 -1
  223. package/dist/components/primitives/Avatar/Avatar.js +1 -1
  224. package/dist/components/primitives/Avatar/Avatar.js.map +1 -1
  225. package/dist/components/primitives/Avatar/Avatar.styles.d.ts.map +1 -1
  226. package/dist/components/primitives/Avatar/Avatar.styles.js +1 -1
  227. package/dist/components/primitives/Avatar/Avatar.styles.js.map +1 -1
  228. package/dist/components/primitives/Button/Button.d.ts.map +1 -1
  229. package/dist/components/primitives/Button/Button.js +2 -5
  230. package/dist/components/primitives/Button/Button.js.map +1 -1
  231. package/dist/components/primitives/Button/Button.styles.d.ts.map +1 -1
  232. package/dist/components/primitives/Button/Button.styles.js +1 -1
  233. package/dist/components/primitives/Button/Button.styles.js.map +1 -1
  234. package/dist/components/primitives/Card/Card.d.ts.map +1 -1
  235. package/dist/components/primitives/Card/Card.js +1 -1
  236. package/dist/components/primitives/Card/Card.js.map +1 -1
  237. package/dist/components/primitives/Card/Card.styles.d.ts.map +1 -1
  238. package/dist/components/primitives/Card/Card.styles.js +1 -1
  239. package/dist/components/primitives/Card/Card.styles.js.map +1 -1
  240. package/dist/components/primitives/Checkbox/Checkbox.d.ts.map +1 -1
  241. package/dist/components/primitives/Checkbox/Checkbox.js +1 -1
  242. package/dist/components/primitives/Checkbox/Checkbox.js.map +1 -1
  243. package/dist/components/primitives/Checkbox/Checkbox.styles.d.ts.map +1 -1
  244. package/dist/components/primitives/Checkbox/Checkbox.styles.js +1 -1
  245. package/dist/components/primitives/Checkbox/Checkbox.styles.js.map +1 -1
  246. package/dist/components/primitives/CopyableText/CopyableText.styles.d.ts.map +1 -1
  247. package/dist/components/primitives/CopyableText/CopyableText.styles.js +1 -1
  248. package/dist/components/primitives/CopyableText/CopyableText.styles.js.map +1 -1
  249. package/dist/components/primitives/DatePicker/DatePicker.d.ts.map +1 -1
  250. package/dist/components/primitives/DatePicker/DatePicker.js +1 -1
  251. package/dist/components/primitives/DatePicker/DatePicker.js.map +1 -1
  252. package/dist/components/primitives/DatePicker/DatePicker.styles.d.ts.map +1 -1
  253. package/dist/components/primitives/DatePicker/DatePicker.styles.js +1 -1
  254. package/dist/components/primitives/DatePicker/DatePicker.styles.js.map +1 -1
  255. package/dist/components/primitives/Dialog/Dialog.d.ts.map +1 -1
  256. package/dist/components/primitives/Dialog/Dialog.js +1 -1
  257. package/dist/components/primitives/Dialog/Dialog.js.map +1 -1
  258. package/dist/components/primitives/Dialog/Dialog.styles.d.ts.map +1 -1
  259. package/dist/components/primitives/Dialog/Dialog.styles.js +1 -1
  260. package/dist/components/primitives/Dialog/Dialog.styles.js.map +1 -1
  261. package/dist/components/primitives/Divider/Divider.d.ts.map +1 -1
  262. package/dist/components/primitives/Divider/Divider.js +1 -1
  263. package/dist/components/primitives/Divider/Divider.js.map +1 -1
  264. package/dist/components/primitives/Divider/Divider.styles.d.ts.map +1 -1
  265. package/dist/components/primitives/Divider/Divider.styles.js +1 -1
  266. package/dist/components/primitives/Divider/Divider.styles.js.map +1 -1
  267. package/dist/components/primitives/FormControl/FormControl.d.ts.map +1 -1
  268. package/dist/components/primitives/FormControl/FormControl.js +1 -1
  269. package/dist/components/primitives/FormControl/FormControl.js.map +1 -1
  270. package/dist/components/primitives/FormControl/FormControl.styles.d.ts.map +1 -1
  271. package/dist/components/primitives/FormControl/FormControl.styles.js +1 -1
  272. package/dist/components/primitives/FormControl/FormControl.styles.js.map +1 -1
  273. package/dist/components/primitives/InputLabel/InputLabel.d.ts.map +1 -1
  274. package/dist/components/primitives/InputLabel/InputLabel.js +1 -1
  275. package/dist/components/primitives/InputLabel/InputLabel.js.map +1 -1
  276. package/dist/components/primitives/InputLabel/InputLabel.styles.d.ts.map +1 -1
  277. package/dist/components/primitives/InputLabel/InputLabel.styles.js +1 -1
  278. package/dist/components/primitives/InputLabel/InputLabel.styles.js.map +1 -1
  279. package/dist/components/primitives/KeyValueInput/KeyValueInput.d.ts.map +1 -1
  280. package/dist/components/primitives/KeyValueInput/KeyValueInput.js +1 -1
  281. package/dist/components/primitives/KeyValueInput/KeyValueInput.js.map +1 -1
  282. package/dist/components/primitives/KeyValueInput/KeyValueInput.styles.d.ts.map +1 -1
  283. package/dist/components/primitives/KeyValueInput/KeyValueInput.styles.js +1 -1
  284. package/dist/components/primitives/KeyValueInput/KeyValueInput.styles.js.map +1 -1
  285. package/dist/components/primitives/Logo/Logo.d.ts.map +1 -1
  286. package/dist/components/primitives/Logo/Logo.js +1 -1
  287. package/dist/components/primitives/Logo/Logo.js.map +1 -1
  288. package/dist/components/primitives/Logo/Logo.styles.d.ts.map +1 -1
  289. package/dist/components/primitives/Logo/Logo.styles.js +1 -1
  290. package/dist/components/primitives/Logo/Logo.styles.js.map +1 -1
  291. package/dist/components/primitives/MultiInput/MultiInput.d.ts.map +1 -1
  292. package/dist/components/primitives/MultiInput/MultiInput.js +1 -1
  293. package/dist/components/primitives/MultiInput/MultiInput.js.map +1 -1
  294. package/dist/components/primitives/MultiInput/MultiInput.styles.d.ts.map +1 -1
  295. package/dist/components/primitives/MultiInput/MultiInput.styles.js +1 -1
  296. package/dist/components/primitives/MultiInput/MultiInput.styles.js.map +1 -1
  297. package/dist/components/primitives/OtpField/OtpField.d.ts.map +1 -1
  298. package/dist/components/primitives/OtpField/OtpField.js +1 -1
  299. package/dist/components/primitives/OtpField/OtpField.js.map +1 -1
  300. package/dist/components/primitives/OtpField/OtpField.styles.d.ts.map +1 -1
  301. package/dist/components/primitives/OtpField/OtpField.styles.js +1 -1
  302. package/dist/components/primitives/OtpField/OtpField.styles.js.map +1 -1
  303. package/dist/components/primitives/PasswordField/PasswordField.d.ts.map +1 -1
  304. package/dist/components/primitives/PasswordField/PasswordField.js +1 -1
  305. package/dist/components/primitives/PasswordField/PasswordField.js.map +1 -1
  306. package/dist/components/primitives/PasswordField/PasswordField.styles.d.ts.map +1 -1
  307. package/dist/components/primitives/PasswordField/PasswordField.styles.js +1 -1
  308. package/dist/components/primitives/PasswordField/PasswordField.styles.js.map +1 -1
  309. package/dist/components/primitives/Select/Select.d.ts.map +1 -1
  310. package/dist/components/primitives/Select/Select.js +1 -1
  311. package/dist/components/primitives/Select/Select.js.map +1 -1
  312. package/dist/components/primitives/Select/Select.styles.d.ts.map +1 -1
  313. package/dist/components/primitives/Select/Select.styles.js +1 -1
  314. package/dist/components/primitives/Select/Select.styles.js.map +1 -1
  315. package/dist/components/primitives/Spinner/Spinner.d.ts +5 -3
  316. package/dist/components/primitives/Spinner/Spinner.d.ts.map +1 -1
  317. package/dist/components/primitives/Spinner/Spinner.js +4 -5
  318. package/dist/components/primitives/Spinner/Spinner.js.map +1 -1
  319. package/dist/components/primitives/Spinner/Spinner.styles.d.ts +4 -1
  320. package/dist/components/primitives/Spinner/Spinner.styles.d.ts.map +1 -1
  321. package/dist/components/primitives/Spinner/Spinner.styles.js +16 -7
  322. package/dist/components/primitives/Spinner/Spinner.styles.js.map +1 -1
  323. package/dist/components/primitives/TextField/TextField.d.ts.map +1 -1
  324. package/dist/components/primitives/TextField/TextField.js +1 -1
  325. package/dist/components/primitives/TextField/TextField.js.map +1 -1
  326. package/dist/components/primitives/TextField/TextField.styles.d.ts.map +1 -1
  327. package/dist/components/primitives/TextField/TextField.styles.js +1 -1
  328. package/dist/components/primitives/TextField/TextField.styles.js.map +1 -1
  329. package/dist/components/primitives/Toggle/Toggle.d.ts.map +1 -1
  330. package/dist/components/primitives/Toggle/Toggle.js +1 -1
  331. package/dist/components/primitives/Toggle/Toggle.js.map +1 -1
  332. package/dist/components/primitives/Toggle/Toggle.styles.d.ts.map +1 -1
  333. package/dist/components/primitives/Toggle/Toggle.styles.js +1 -1
  334. package/dist/components/primitives/Toggle/Toggle.styles.js.map +1 -1
  335. package/dist/components/primitives/Tooltip/Tooltip.d.ts.map +1 -1
  336. package/dist/components/primitives/Tooltip/Tooltip.js +1 -1
  337. package/dist/components/primitives/Tooltip/Tooltip.js.map +1 -1
  338. package/dist/components/primitives/Tooltip/Tooltip.styles.d.ts.map +1 -1
  339. package/dist/components/primitives/Tooltip/Tooltip.styles.js +1 -1
  340. package/dist/components/primitives/Tooltip/Tooltip.styles.js.map +1 -1
  341. package/dist/components/primitives/Typography/Typography.d.ts.map +1 -1
  342. package/dist/components/primitives/Typography/Typography.js +1 -1
  343. package/dist/components/primitives/Typography/Typography.js.map +1 -1
  344. package/dist/components/primitives/Typography/Typography.styles.d.ts.map +1 -1
  345. package/dist/components/primitives/Typography/Typography.styles.js +1 -1
  346. package/dist/components/primitives/Typography/Typography.styles.js.map +1 -1
  347. package/dist/contexts/ThunderID/ThunderIDProvider.d.ts.map +1 -1
  348. package/dist/contexts/ThunderID/ThunderIDProvider.js +4 -1
  349. package/dist/contexts/ThunderID/ThunderIDProvider.js.map +1 -1
  350. package/dist/models/config.d.ts +10 -1
  351. package/dist/models/config.d.ts.map +1 -1
  352. package/dist/styles/emotion.d.ts +36 -0
  353. package/dist/styles/emotion.d.ts.map +1 -0
  354. package/dist/styles/emotion.js +58 -0
  355. package/dist/styles/emotion.js.map +1 -0
  356. package/package.json +2 -2
@@ -1 +1 @@
1
- {"version":3,"file":"Spinner.cjs","names":["Spinner: FC<SpinnerProps>","useTheme","styles: Record<string, string>","useStyles"],"sources":["../../../../../src/components/primitives/Spinner/Spinner.tsx"],"sourcesContent":["// Copyright 2025 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {cx} from '@emotion/css';\nimport {withVendorCSSClassPrefix, bem} from '@thunderid/browser';\nimport {FC, CSSProperties} from 'react';\nimport useStyles from './Spinner.styles';\nimport useTheme from '../../../contexts/Theme/useTheme';\n\nexport type SpinnerSize = 'small' | 'medium' | 'large';\n\nexport interface SpinnerProps {\n /**\n * Additional CSS class names\n */\n className?: string;\n /**\n * Custom color for the spinner\n */\n color?: string;\n /**\n * Size of the spinner\n */\n size?: SpinnerSize;\n /**\n * Custom styles\n */\n style?: CSSProperties;\n}\n\n/**\n * Spinner component for loading states\n *\n * @example\n * ```tsx\n * // Basic spinner\n * <Spinner />\n *\n * // Large spinner with custom color\n * <Spinner size=\"large\" color=\"#3b82f6\" />\n *\n * // Small spinner\n * <Spinner size=\"small\" />\n * ```\n */\nconst Spinner: FC<SpinnerProps> = ({size = 'medium', color, className, style}: SpinnerProps) => {\n const {theme, colorScheme}: ReturnType<typeof useTheme> = useTheme();\n const styles: Record<string, string> = useStyles(theme, colorScheme, size, color);\n\n const spinnerClassName: string = cx(\n withVendorCSSClassPrefix(bem('spinner')),\n styles['spinner'],\n size === 'small' && styles['spinnerSmall'],\n size === 'medium' && styles['spinnerMedium'],\n size === 'large' && styles['spinnerLarge'],\n className,\n );\n\n return <span className={spinnerClassName} style={style} role=\"status\" aria-label=\"Loading\" />;\n};\n\nexport default Spinner;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AA6CA,MAAMA,WAA6B,EAAC,OAAO,UAAU,OAAO,WAAW,YAAyB;CAC9F,MAAM,EAAC,OAAO,gBAA4CC,0BAAU;CACpE,MAAMC,SAAiCC,+BAAU,OAAO,aAAa,MAAM,MAAM;AAWjF,QAAO,2CAAC;EAAK,gHARkB,UAAU,CAAC,EACxC,OAAO,YACP,SAAS,WAAW,OAAO,iBAC3B,SAAS,YAAY,OAAO,kBAC5B,SAAS,WAAW,OAAO,iBAC3B,UACD;EAEgD;EAAO,MAAK;EAAS,cAAW;GAAY;;AAG/F,sBAAe"}
1
+ {"version":3,"file":"Spinner.cjs","names":["Spinner: FC<SpinnerProps>","useTheme","styles: Record<string, string>","useStyles","cx"],"sources":["../../../../../src/components/primitives/Spinner/Spinner.tsx"],"sourcesContent":["// Copyright 2025 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {withVendorCSSClassPrefix, bem} from '@thunderid/browser';\nimport {FC} from 'react';\nimport useStyles from './Spinner.styles';\nimport useTheme from '../../../contexts/Theme/useTheme';\nimport {cx} from '../../../styles/emotion';\n\nexport type SpinnerSize = 'small' | 'medium' | 'large';\n\nexport interface SpinnerProps {\n /**\n * Additional CSS class names\n */\n className?: string;\n /**\n * Custom color for the spinner\n */\n color?: string;\n /**\n * Size of the spinner\n */\n size?: SpinnerSize;\n /**\n * Optional explicit width/height (CSS length, e.g. `'24px'` or `'calc(...)'`) that overrides\n * the `size`-based default dimensions. Generates its own Emotion class internally rather than\n * accepting an inline `style` object, so it participates in the shared CSP nonce automatically.\n */\n widthOverride?: string;\n}\n\n/**\n * Spinner component for loading states\n *\n * @example\n * ```tsx\n * // Basic spinner\n * <Spinner />\n *\n * // Large spinner with custom color\n * <Spinner size=\"large\" color=\"#3b82f6\" />\n *\n * // Small spinner\n * <Spinner size=\"small\" />\n * ```\n */\nconst Spinner: FC<SpinnerProps> = ({size = 'medium', color, className, widthOverride = undefined}: SpinnerProps) => {\n const {theme, colorScheme}: ReturnType<typeof useTheme> = useTheme();\n const styles: Record<string, string> = useStyles(theme, colorScheme, size, color, widthOverride);\n\n const spinnerClassName: string = cx(\n withVendorCSSClassPrefix(bem('spinner')),\n styles['spinner'],\n size === 'small' && styles['spinnerSmall'],\n size === 'medium' && styles['spinnerMedium'],\n size === 'large' && styles['spinnerLarge'],\n widthOverride && styles['spinnerCustomSize'],\n className,\n );\n\n return <span className={spinnerClassName} role=\"status\" aria-label=\"Loading\" />;\n};\n\nexport default Spinner;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AA+CA,MAAMA,WAA6B,EAAC,OAAO,UAAU,OAAO,WAAW,gBAAgB,aAA6B;CAClH,MAAM,EAAC,OAAO,gBAA4CC,0BAAU;CACpE,MAAMC,SAAiCC,+BAAU,OAAO,aAAa,MAAM,OAAO,cAAc;AAYhG,QAAO,2CAAC;EAAK,WAVoBC,kGACF,UAAU,CAAC,EACxC,OAAO,YACP,SAAS,WAAW,OAAO,iBAC3B,SAAS,YAAY,OAAO,kBAC5B,SAAS,WAAW,OAAO,iBAC3B,iBAAiB,OAAO,sBACxB,UACD;EAEyC,MAAK;EAAS,cAAW;GAAY;;AAGjF,sBAAe"}
@@ -1,8 +1,7 @@
1
1
  const require_rolldown_runtime = require('../../../_virtual/rolldown_runtime.cjs');
2
+ const require_emotion = require('../../../styles/emotion.cjs');
2
3
  let react = require("react");
3
4
  react = require_rolldown_runtime.__toESM(react);
4
- let __emotion_css = require("@emotion/css");
5
- __emotion_css = require_rolldown_runtime.__toESM(__emotion_css);
6
5
 
7
6
  //#region src/components/primitives/Spinner/Spinner.styles.ts
8
7
  /**
@@ -11,9 +10,12 @@ __emotion_css = require_rolldown_runtime.__toESM(__emotion_css);
11
10
  * @param colorScheme - The current color scheme (used for memoization)
12
11
  * @param size - The size of the spinner
13
12
  * @param color - The color of the spinner
13
+ * @param customSize - Optional explicit width/height (CSS length) that overrides the size-based
14
+ * default, e.g. when a parent component (like `Button`) needs the spinner to track a
15
+ * theme-derived dimension instead of one of the fixed `size` presets.
14
16
  * @returns Object containing CSS class names for component styling
15
17
  */
16
- const useStyles = (theme, colorScheme, size, color) => (0, react.useMemo)(() => {
18
+ const useStyles = (theme, colorScheme, size, color, customSize) => (0, react.useMemo)(() => {
17
19
  const spinnerColor = color || theme.vars.colors.primary.main;
18
20
  const spinnerSizes = {
19
21
  large: "32px",
@@ -21,13 +23,13 @@ const useStyles = (theme, colorScheme, size, color) => (0, react.useMemo)(() =>
21
23
  small: "16px"
22
24
  };
23
25
  const spinnerSize = spinnerSizes[size];
24
- const spinner = __emotion_css.css`
26
+ const spinner = require_emotion.css`
25
27
  width: ${spinnerSize};
26
28
  height: ${spinnerSize};
27
29
  border: 2px solid transparent;
28
30
  border-top: 2px solid ${spinnerColor};
29
31
  border-radius: 50%;
30
- animation: ${__emotion_css.keyframes`
32
+ animation: ${require_emotion.keyframes`
31
33
  0% {
32
34
  transform: rotate(0deg);
33
35
  }
@@ -37,20 +39,25 @@ const useStyles = (theme, colorScheme, size, color) => (0, react.useMemo)(() =>
37
39
  `} 1s linear infinite;
38
40
  display: inline-block;
39
41
  `;
40
- const spinnerSmall = __emotion_css.css`
42
+ const spinnerSmall = require_emotion.css`
41
43
  width: ${spinnerSizes["small"]};
42
44
  height: ${spinnerSizes["small"]};
43
45
  `;
44
- const spinnerMedium = __emotion_css.css`
46
+ const spinnerMedium = require_emotion.css`
45
47
  width: ${spinnerSizes["medium"]};
46
48
  height: ${spinnerSizes["medium"]};
47
49
  `;
48
- return {
49
- spinner,
50
- spinnerLarge: __emotion_css.css`
50
+ const spinnerLarge = require_emotion.css`
51
51
  width: ${spinnerSizes["large"]};
52
52
  height: ${spinnerSizes["large"]};
53
- `,
53
+ `;
54
+ return {
55
+ spinner,
56
+ spinnerCustomSize: customSize ? require_emotion.css`
57
+ width: ${customSize};
58
+ height: ${customSize};
59
+ ` : "",
60
+ spinnerLarge,
54
61
  spinnerMedium,
55
62
  spinnerSmall
56
63
  };
@@ -58,7 +65,8 @@ const useStyles = (theme, colorScheme, size, color) => (0, react.useMemo)(() =>
58
65
  theme,
59
66
  colorScheme,
60
67
  size,
61
- color
68
+ color,
69
+ customSize
62
70
  ]);
63
71
  var Spinner_styles_default = useStyles;
64
72
 
@@ -1 +1 @@
1
- {"version":3,"file":"Spinner.styles.cjs","names":["spinnerColor: string","spinnerSizes: Record<string, string>","spinnerSize: string","spinner: string","spinnerSmall: string","spinnerMedium: string"],"sources":["../../../../../src/components/primitives/Spinner/Spinner.styles.ts"],"sourcesContent":["// Copyright 2025 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {css, keyframes} from '@emotion/css';\nimport {Theme} from '@thunderid/browser';\nimport {useMemo} from 'react';\n\nexport type SpinnerSize = 'small' | 'medium' | 'large';\n\n/**\n * Creates styles for the Spinner component using BEM methodology\n * @param theme - The theme object containing design tokens\n * @param colorScheme - The current color scheme (used for memoization)\n * @param size - The size of the spinner\n * @param color - The color of the spinner\n * @returns Object containing CSS class names for component styling\n */\nconst useStyles = (theme: Theme, colorScheme: string, size: SpinnerSize, color?: string): Record<string, string> =>\n useMemo(() => {\n const spinnerColor: string = color || theme.vars.colors.primary.main;\n\n const spinnerSizes: Record<string, string> = {\n large: '32px',\n medium: '20px',\n small: '16px',\n };\n\n const spinnerSize: string = spinnerSizes[size];\n\n const spinAnimation: string = keyframes`\n 0% {\n transform: rotate(0deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n `;\n\n const spinner: string = css`\n width: ${spinnerSize};\n height: ${spinnerSize};\n border: 2px solid transparent;\n border-top: 2px solid ${spinnerColor};\n border-radius: 50%;\n animation: ${spinAnimation} 1s linear infinite;\n display: inline-block;\n `;\n\n const spinnerSmall: string = css`\n width: ${spinnerSizes['small']};\n height: ${spinnerSizes['small']};\n `;\n\n const spinnerMedium: string = css`\n width: ${spinnerSizes['medium']};\n height: ${spinnerSizes['medium']};\n `;\n\n const spinnerLarge: string = css`\n width: ${spinnerSizes['large']};\n height: ${spinnerSizes['large']};\n `;\n\n return {\n spinner,\n spinnerLarge,\n spinnerMedium,\n spinnerSmall,\n };\n }, [theme, colorScheme, size, color]);\n\nexport default useStyles;\n"],"mappings":";;;;;;;;;;;;;;;AAiBA,MAAM,aAAa,OAAc,aAAqB,MAAmB,mCACzD;CACZ,MAAMA,eAAuB,SAAS,MAAM,KAAK,OAAO,QAAQ;CAEhE,MAAMC,eAAuC;EAC3C,OAAO;EACP,QAAQ;EACR,OAAO;EACR;CAED,MAAMC,cAAsB,aAAa;CAWzC,MAAMC,UAAkB,iBAAG;eAChB,YAAY;gBACX,YAAY;;8BAEE,aAAa;;mBAbT,uBAAS;;;;;;;MAeV;;;CAI7B,MAAMC,eAAuB,iBAAG;eACrB,aAAa,SAAS;gBACrB,aAAa,SAAS;;CAGlC,MAAMC,gBAAwB,iBAAG;eACtB,aAAa,UAAU;gBACtB,aAAa,UAAU;;AAQnC,QAAO;EACL;EACA,cAP2B,iBAAG;eACrB,aAAa,SAAS;gBACrB,aAAa,SAAS;;EAMhC;EACA;EACD;GACA;CAAC;CAAO;CAAa;CAAM;CAAM,CAAC;AAEvC,6BAAe"}
1
+ {"version":3,"file":"Spinner.styles.cjs","names":["spinnerColor: string","spinnerSizes: Record<string, string>","spinnerSize: string","spinner: string","spinnerSmall: string","spinnerMedium: string","spinnerLarge: string"],"sources":["../../../../../src/components/primitives/Spinner/Spinner.styles.ts"],"sourcesContent":["// Copyright 2025 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {Theme} from '@thunderid/browser';\nimport {useMemo} from 'react';\nimport {css, keyframes} from '../../../styles/emotion';\n\nexport type SpinnerSize = 'small' | 'medium' | 'large';\n\n/**\n * Creates styles for the Spinner component using BEM methodology\n * @param theme - The theme object containing design tokens\n * @param colorScheme - The current color scheme (used for memoization)\n * @param size - The size of the spinner\n * @param color - The color of the spinner\n * @param customSize - Optional explicit width/height (CSS length) that overrides the size-based\n * default, e.g. when a parent component (like `Button`) needs the spinner to track a\n * theme-derived dimension instead of one of the fixed `size` presets.\n * @returns Object containing CSS class names for component styling\n */\nconst useStyles = (\n theme: Theme,\n colorScheme: string,\n size: SpinnerSize,\n color?: string,\n customSize?: string,\n): Record<string, string> =>\n useMemo(() => {\n const spinnerColor: string = color || theme.vars.colors.primary.main;\n\n const spinnerSizes: Record<string, string> = {\n large: '32px',\n medium: '20px',\n small: '16px',\n };\n\n const spinnerSize: string = spinnerSizes[size];\n\n const spinAnimation: string = keyframes`\n 0% {\n transform: rotate(0deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n `;\n\n const spinner: string = css`\n width: ${spinnerSize};\n height: ${spinnerSize};\n border: 2px solid transparent;\n border-top: 2px solid ${spinnerColor};\n border-radius: 50%;\n animation: ${spinAnimation} 1s linear infinite;\n display: inline-block;\n `;\n\n const spinnerSmall: string = css`\n width: ${spinnerSizes['small']};\n height: ${spinnerSizes['small']};\n `;\n\n const spinnerMedium: string = css`\n width: ${spinnerSizes['medium']};\n height: ${spinnerSizes['medium']};\n `;\n\n const spinnerLarge: string = css`\n width: ${spinnerSizes['large']};\n height: ${spinnerSizes['large']};\n `;\n\n const spinnerCustomSize: string = customSize\n ? css`\n width: ${customSize};\n height: ${customSize};\n `\n : '';\n\n return {\n spinner,\n spinnerCustomSize,\n spinnerLarge,\n spinnerMedium,\n spinnerSmall,\n };\n }, [theme, colorScheme, size, color, customSize]);\n\nexport default useStyles;\n"],"mappings":";;;;;;;;;;;;;;;;;AAoBA,MAAM,aACJ,OACA,aACA,MACA,OACA,wCAEc;CACZ,MAAMA,eAAuB,SAAS,MAAM,KAAK,OAAO,QAAQ;CAEhE,MAAMC,eAAuC;EAC3C,OAAO;EACP,QAAQ;EACR,OAAO;EACR;CAED,MAAMC,cAAsB,aAAa;CAWzC,MAAMC,UAAkB,mBAAG;eAChB,YAAY;gBACX,YAAY;;8BAEE,aAAa;;mBAbT,yBAAS;;;;;;;MAeV;;;CAI7B,MAAMC,eAAuB,mBAAG;eACrB,aAAa,SAAS;gBACrB,aAAa,SAAS;;CAGlC,MAAMC,gBAAwB,mBAAG;eACtB,aAAa,UAAU;gBACtB,aAAa,UAAU;;CAGnC,MAAMC,eAAuB,mBAAG;eACrB,aAAa,SAAS;gBACrB,aAAa,SAAS;;AAUlC,QAAO;EACL;EACA,mBATgC,aAC9B,mBAAG;mBACQ,WAAW;oBACV,WAAW;YAEvB;EAKF;EACA;EACA;EACD;GACA;CAAC;CAAO;CAAa;CAAM;CAAO;CAAW,CAAC;AAEnD,6BAAe"}
@@ -1,4 +1,5 @@
1
1
  const require_rolldown_runtime = require('../../../_virtual/rolldown_runtime.cjs');
2
+ const require_emotion = require('../../../styles/emotion.cjs');
2
3
  const require_useTheme = require('../../../contexts/Theme/useTheme.cjs');
3
4
  const require_FormControl = require('../FormControl/FormControl.cjs');
4
5
  const require_InputLabel = require('../InputLabel/InputLabel.cjs');
@@ -7,22 +8,20 @@ let __thunderid_browser = require("@thunderid/browser");
7
8
  __thunderid_browser = require_rolldown_runtime.__toESM(__thunderid_browser);
8
9
  let react_jsx_runtime = require("react/jsx-runtime");
9
10
  react_jsx_runtime = require_rolldown_runtime.__toESM(react_jsx_runtime);
10
- let __emotion_css = require("@emotion/css");
11
- __emotion_css = require_rolldown_runtime.__toESM(__emotion_css);
12
11
 
13
12
  //#region src/components/primitives/TextField/TextField.tsx
14
13
  const TextField = ({ label, error, required, className, disabled, helperText, startIcon, endIcon, onStartIconClick, onEndIconClick, type = "text", style = {},...rest }) => {
15
14
  const { theme, colorScheme } = require_useTheme.default();
16
15
  const hasError = !!error;
17
16
  const styles = require_TextField_styles.default(theme, colorScheme, disabled ?? false, hasError, !!startIcon, !!endIcon);
18
- const inputClassName = (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("text-field", "input")), styles["input"], hasError && styles["inputError"], disabled && styles["inputDisabled"]);
19
- const containerClassName = (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("text-field", "container")), styles["inputContainer"]);
20
- const startIconClassName = (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("text-field", "start-icon")), styles["startIcon"]);
21
- const endIconClassName = (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("text-field", "end-icon")), styles["endIcon"]);
17
+ const inputClassName = require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("text-field", "input")), styles["input"], hasError && styles["inputError"], disabled && styles["inputDisabled"]);
18
+ const containerClassName = require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("text-field", "container")), styles["inputContainer"]);
19
+ const startIconClassName = require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("text-field", "start-icon")), styles["startIcon"]);
20
+ const endIconClassName = require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("text-field", "end-icon")), styles["endIcon"]);
22
21
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(require_FormControl.default, {
23
22
  error,
24
23
  helperText,
25
- className: (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("text-field")), className),
24
+ className: require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("text-field")), className),
26
25
  style,
27
26
  children: [label && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_InputLabel.default, {
28
27
  required,
@@ -1 +1 @@
1
- {"version":3,"file":"TextField.cjs","names":["TextField: FC<TextFieldProps>","useTheme","styles: Record<string, string>","useStyles","inputClassName: string","containerClassName: string","startIconClassName: string","endIconClassName: string","FormControl","InputLabel"],"sources":["../../../../../src/components/primitives/TextField/TextField.tsx"],"sourcesContent":["// Copyright 2024 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {cx} from '@emotion/css';\nimport {withVendorCSSClassPrefix, bem} from '@thunderid/browser';\nimport {FC, InputHTMLAttributes, ReactNode} from 'react';\nimport useStyles from './TextField.styles';\nimport useTheme from '../../../contexts/Theme/useTheme';\nimport FormControl from '../FormControl/FormControl';\nimport InputLabel from '../InputLabel/InputLabel';\n\nexport interface TextFieldProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'className'> {\n /**\n * Additional CSS class names\n */\n className?: string;\n /**\n * Whether the field is disabled\n */\n disabled?: boolean;\n /**\n * Icon to display at the end (right) of the input\n */\n endIcon?: ReactNode;\n /**\n * Error message to display below the input\n */\n error?: string;\n /**\n * Helper text to display below the input\n */\n helperText?: string;\n /**\n * Label text to display above the input\n */\n label?: string;\n /**\n * Click handler for the end icon\n */\n onEndIconClick?: () => void;\n /**\n * Click handler for the start icon\n */\n onStartIconClick?: () => void;\n /**\n * Whether the field is required\n */\n required?: boolean;\n /**\n * Icon to display at the start (left) of the input\n */\n startIcon?: ReactNode;\n}\n\nconst TextField: FC<TextFieldProps> = ({\n label,\n error,\n required,\n className,\n disabled,\n helperText,\n startIcon,\n endIcon,\n onStartIconClick,\n onEndIconClick,\n type = 'text',\n style = {},\n ...rest\n}: TextFieldProps) => {\n const {theme, colorScheme}: ReturnType<typeof useTheme> = useTheme();\n const hasError = !!error;\n const hasStartIcon = !!startIcon;\n const hasEndIcon = !!endIcon;\n const styles: Record<string, string> = useStyles(\n theme,\n colorScheme,\n disabled ?? false,\n hasError,\n hasStartIcon,\n hasEndIcon,\n );\n\n const inputClassName: string = cx(\n withVendorCSSClassPrefix(bem('text-field', 'input')),\n styles['input'],\n hasError && styles['inputError'],\n disabled && styles['inputDisabled'],\n );\n\n const containerClassName: string = cx(\n withVendorCSSClassPrefix(bem('text-field', 'container')),\n styles['inputContainer'],\n );\n\n const startIconClassName: string = cx(withVendorCSSClassPrefix(bem('text-field', 'start-icon')), styles['startIcon']);\n\n const endIconClassName: string = cx(withVendorCSSClassPrefix(bem('text-field', 'end-icon')), styles['endIcon']);\n\n return (\n <FormControl\n error={error}\n helperText={helperText}\n className={cx(withVendorCSSClassPrefix(bem('text-field')), className)}\n style={style}\n >\n {label && (\n <InputLabel required={required} error={hasError}>\n {label}\n </InputLabel>\n )}\n <div className={containerClassName}>\n {startIcon && (\n <div\n className={startIconClassName}\n onClick={onStartIconClick}\n role={onStartIconClick ? 'button' : undefined}\n tabIndex={onStartIconClick && !disabled ? 0 : undefined}\n aria-label=\"Start icon\"\n >\n {startIcon}\n </div>\n )}\n <input\n className={inputClassName}\n type={type}\n disabled={disabled}\n aria-invalid={hasError}\n aria-required={required}\n {...rest}\n />\n {endIcon && (\n <div\n className={endIconClassName}\n onClick={onEndIconClick}\n role={onEndIconClick ? 'button' : undefined}\n tabIndex={onEndIconClick && !disabled ? 0 : undefined}\n aria-label=\"End icon\"\n >\n {endIcon}\n </div>\n )}\n </div>\n </FormControl>\n );\n};\n\nexport default TextField;\n"],"mappings":";;;;;;;;;;;;;AAsDA,MAAMA,aAAiC,EACrC,OACA,OACA,UACA,WACA,UACA,YACA,WACA,SACA,kBACA,gBACA,OAAO,QACP,QAAQ,EAAE,CACV,GAAG,WACiB;CACpB,MAAM,EAAC,OAAO,gBAA4CC,0BAAU;CACpE,MAAM,WAAW,CAAC,CAAC;CAGnB,MAAMC,SAAiCC,iCACrC,OACA,aACA,YAAY,OACZ,UANmB,CAAC,CAAC,WACJ,CAAC,CAAC,QAQpB;CAED,MAAMC,sHACyB,cAAc,QAAQ,CAAC,EACpD,OAAO,UACP,YAAY,OAAO,eACnB,YAAY,OAAO,iBACpB;CAED,MAAMC,0HACyB,cAAc,YAAY,CAAC,EACxD,OAAO,kBACR;CAED,MAAMC,0HAA6D,cAAc,aAAa,CAAC,EAAE,OAAO,aAAa;CAErH,MAAMC,wHAA2D,cAAc,WAAW,CAAC,EAAE,OAAO,WAAW;AAE/G,QACE,4CAACC;EACQ;EACK;EACZ,gHAA2C,aAAa,CAAC,EAAE,UAAU;EAC9D;aAEN,SACC,2CAACC;GAAqB;GAAU,OAAO;aACpC;IACU,EAEf,4CAAC;GAAI,WAAW;;IACb,aACC,2CAAC;KACC,WAAW;KACX,SAAS;KACT,MAAM,mBAAmB,WAAW;KACpC,UAAU,oBAAoB,CAAC,WAAW,IAAI;KAC9C,cAAW;eAEV;MACG;IAER,2CAAC;KACC,WAAW;KACL;KACI;KACV,gBAAc;KACd,iBAAe;KACf,GAAI;MACJ;IACD,WACC,2CAAC;KACC,WAAW;KACX,SAAS;KACT,MAAM,iBAAiB,WAAW;KAClC,UAAU,kBAAkB,CAAC,WAAW,IAAI;KAC5C,cAAW;eAEV;MACG;;IAEJ;GACM;;AAIlB,wBAAe"}
1
+ {"version":3,"file":"TextField.cjs","names":["TextField: FC<TextFieldProps>","useTheme","styles: Record<string, string>","useStyles","inputClassName: string","cx","containerClassName: string","startIconClassName: string","endIconClassName: string","FormControl","InputLabel"],"sources":["../../../../../src/components/primitives/TextField/TextField.tsx"],"sourcesContent":["// Copyright 2024 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {withVendorCSSClassPrefix, bem} from '@thunderid/browser';\nimport {FC, InputHTMLAttributes, ReactNode} from 'react';\nimport useStyles from './TextField.styles';\nimport useTheme from '../../../contexts/Theme/useTheme';\nimport {cx} from '../../../styles/emotion';\nimport FormControl from '../FormControl/FormControl';\nimport InputLabel from '../InputLabel/InputLabel';\n\nexport interface TextFieldProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'className'> {\n /**\n * Additional CSS class names\n */\n className?: string;\n /**\n * Whether the field is disabled\n */\n disabled?: boolean;\n /**\n * Icon to display at the end (right) of the input\n */\n endIcon?: ReactNode;\n /**\n * Error message to display below the input\n */\n error?: string;\n /**\n * Helper text to display below the input\n */\n helperText?: string;\n /**\n * Label text to display above the input\n */\n label?: string;\n /**\n * Click handler for the end icon\n */\n onEndIconClick?: () => void;\n /**\n * Click handler for the start icon\n */\n onStartIconClick?: () => void;\n /**\n * Whether the field is required\n */\n required?: boolean;\n /**\n * Icon to display at the start (left) of the input\n */\n startIcon?: ReactNode;\n}\n\nconst TextField: FC<TextFieldProps> = ({\n label,\n error,\n required,\n className,\n disabled,\n helperText,\n startIcon,\n endIcon,\n onStartIconClick,\n onEndIconClick,\n type = 'text',\n style = {},\n ...rest\n}: TextFieldProps) => {\n const {theme, colorScheme}: ReturnType<typeof useTheme> = useTheme();\n const hasError = !!error;\n const hasStartIcon = !!startIcon;\n const hasEndIcon = !!endIcon;\n const styles: Record<string, string> = useStyles(\n theme,\n colorScheme,\n disabled ?? false,\n hasError,\n hasStartIcon,\n hasEndIcon,\n );\n\n const inputClassName: string = cx(\n withVendorCSSClassPrefix(bem('text-field', 'input')),\n styles['input'],\n hasError && styles['inputError'],\n disabled && styles['inputDisabled'],\n );\n\n const containerClassName: string = cx(\n withVendorCSSClassPrefix(bem('text-field', 'container')),\n styles['inputContainer'],\n );\n\n const startIconClassName: string = cx(withVendorCSSClassPrefix(bem('text-field', 'start-icon')), styles['startIcon']);\n\n const endIconClassName: string = cx(withVendorCSSClassPrefix(bem('text-field', 'end-icon')), styles['endIcon']);\n\n return (\n <FormControl\n error={error}\n helperText={helperText}\n className={cx(withVendorCSSClassPrefix(bem('text-field')), className)}\n style={style}\n >\n {label && (\n <InputLabel required={required} error={hasError}>\n {label}\n </InputLabel>\n )}\n <div className={containerClassName}>\n {startIcon && (\n <div\n className={startIconClassName}\n onClick={onStartIconClick}\n role={onStartIconClick ? 'button' : undefined}\n tabIndex={onStartIconClick && !disabled ? 0 : undefined}\n aria-label=\"Start icon\"\n >\n {startIcon}\n </div>\n )}\n <input\n className={inputClassName}\n type={type}\n disabled={disabled}\n aria-invalid={hasError}\n aria-required={required}\n {...rest}\n />\n {endIcon && (\n <div\n className={endIconClassName}\n onClick={onEndIconClick}\n role={onEndIconClick ? 'button' : undefined}\n tabIndex={onEndIconClick && !disabled ? 0 : undefined}\n aria-label=\"End icon\"\n >\n {endIcon}\n </div>\n )}\n </div>\n </FormControl>\n );\n};\n\nexport default TextField;\n"],"mappings":";;;;;;;;;;;;AAsDA,MAAMA,aAAiC,EACrC,OACA,OACA,UACA,WACA,UACA,YACA,WACA,SACA,kBACA,gBACA,OAAO,QACP,QAAQ,EAAE,CACV,GAAG,WACiB;CACpB,MAAM,EAAC,OAAO,gBAA4CC,0BAAU;CACpE,MAAM,WAAW,CAAC,CAAC;CAGnB,MAAMC,SAAiCC,iCACrC,OACA,aACA,YAAY,OACZ,UANmB,CAAC,CAAC,WACJ,CAAC,CAAC,QAQpB;CAED,MAAMC,iBAAyBC,kGACA,cAAc,QAAQ,CAAC,EACpD,OAAO,UACP,YAAY,OAAO,eACnB,YAAY,OAAO,iBACpB;CAED,MAAMC,qBAA6BD,kGACJ,cAAc,YAAY,CAAC,EACxD,OAAO,kBACR;CAED,MAAME,qBAA6BF,kGAAgC,cAAc,aAAa,CAAC,EAAE,OAAO,aAAa;CAErH,MAAMG,mBAA2BH,kGAAgC,cAAc,WAAW,CAAC,EAAE,OAAO,WAAW;AAE/G,QACE,4CAACI;EACQ;EACK;EACZ,WAAWJ,kGAAgC,aAAa,CAAC,EAAE,UAAU;EAC9D;aAEN,SACC,2CAACK;GAAqB;GAAU,OAAO;aACpC;IACU,EAEf,4CAAC;GAAI,WAAW;;IACb,aACC,2CAAC;KACC,WAAW;KACX,SAAS;KACT,MAAM,mBAAmB,WAAW;KACpC,UAAU,oBAAoB,CAAC,WAAW,IAAI;KAC9C,cAAW;eAEV;MACG;IAER,2CAAC;KACC,WAAW;KACL;KACI;KACV,gBAAc;KACd,iBAAe;KACf,GAAI;MACJ;IACD,WACC,2CAAC;KACC,WAAW;KACX,SAAS;KACT,MAAM,iBAAiB,WAAW;KAClC,UAAU,kBAAkB,CAAC,WAAW,IAAI;KAC5C,cAAW;eAEV;MACG;;IAEJ;GACM;;AAIlB,wBAAe"}
@@ -1,8 +1,7 @@
1
1
  const require_rolldown_runtime = require('../../../_virtual/rolldown_runtime.cjs');
2
+ const require_emotion = require('../../../styles/emotion.cjs');
2
3
  let react = require("react");
3
4
  react = require_rolldown_runtime.__toESM(react);
4
- let __emotion_css = require("@emotion/css");
5
- __emotion_css = require_rolldown_runtime.__toESM(__emotion_css);
6
5
 
7
6
  //#region src/components/primitives/TextField/TextField.styles.ts
8
7
  /**
@@ -18,12 +17,12 @@ __emotion_css = require_rolldown_runtime.__toESM(__emotion_css);
18
17
  const useStyles = (theme, colorScheme, disabled, hasError, hasStartIcon, hasEndIcon) => (0, react.useMemo)(() => {
19
18
  const inlineStartPadding = hasStartIcon ? `calc(${theme.vars.spacing.unit} * 5)` : `calc(${theme.vars.spacing.unit} * 1.5)`;
20
19
  const inlineEndPadding = hasEndIcon ? `calc(${theme.vars.spacing.unit} * 5)` : `calc(${theme.vars.spacing.unit} * 1.5)`;
21
- const inputContainer = __emotion_css.css`
20
+ const inputContainer = require_emotion.css`
22
21
  position: relative;
23
22
  display: flex;
24
23
  align-items: center;
25
24
  `;
26
- const input = __emotion_css.css`
25
+ const input = require_emotion.css`
27
26
  width: 100%;
28
27
  padding-block: ${theme.vars.spacing.unit};
29
28
  padding-inline-start: ${inlineStartPadding};
@@ -58,7 +57,7 @@ const useStyles = (theme, colorScheme, disabled, hasError, hasStartIcon, hasEndI
58
57
  opacity: 0.7;
59
58
  }
60
59
  `;
61
- const inputError = __emotion_css.css`
60
+ const inputError = require_emotion.css`
62
61
  border-color: ${theme.vars.colors.error.main};
63
62
 
64
63
  &:focus {
@@ -70,12 +69,12 @@ const useStyles = (theme, colorScheme, disabled, hasError, hasStartIcon, hasEndI
70
69
  border-color: ${theme.vars.colors.error.main};
71
70
  }
72
71
  `;
73
- const inputDisabled = __emotion_css.css`
72
+ const inputDisabled = require_emotion.css`
74
73
  background-color: ${theme.vars.colors.background.disabled};
75
74
  opacity: 0.6;
76
75
  cursor: not-allowed;
77
76
  `;
78
- const icon = __emotion_css.css`
77
+ const icon = require_emotion.css`
79
78
  position: absolute;
80
79
  background: none;
81
80
  border: none;
@@ -101,12 +100,12 @@ const useStyles = (theme, colorScheme, disabled, hasError, hasStartIcon, hasEndI
101
100
  outline-offset: 2px;
102
101
  }
103
102
  `;
104
- const startIcon = __emotion_css.css`
103
+ const startIcon = require_emotion.css`
105
104
  ${icon};
106
105
  inset-inline-start: ${theme.vars.spacing.unit};
107
106
  `;
108
107
  return {
109
- endIcon: __emotion_css.css`
108
+ endIcon: require_emotion.css`
110
109
  ${icon};
111
110
  inset-inline-end: ${theme.vars.spacing.unit};
112
111
  `,
@@ -1 +1 @@
1
- {"version":3,"file":"TextField.styles.cjs","names":["inlineStartPadding: string","inlineEndPadding: string","inputContainer: string","input: string","inputError: string","inputDisabled: string","icon: string","startIcon: string"],"sources":["../../../../../src/components/primitives/TextField/TextField.styles.ts"],"sourcesContent":["// Copyright 2024 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {css} from '@emotion/css';\nimport {Theme} from '@thunderid/browser';\nimport {useMemo} from 'react';\n\n/**\n * Creates styles for the TextField component using BEM methodology\n * @param theme - The theme object containing design tokens\n * @param colorScheme - The current color scheme (used for memoization)\n * @param disabled - Whether the component is disabled\n * @param hasError - Whether the component has an error\n * @param hasStartIcon - Whether the component has a start icon\n * @param hasEndIcon - Whether the component has an end icon\n * @returns Object containing CSS class names for component styling\n */\nconst useStyles = (\n theme: Theme,\n colorScheme: string,\n disabled: boolean,\n hasError: boolean,\n hasStartIcon: boolean,\n hasEndIcon: boolean,\n): Record<string, string> =>\n useMemo(() => {\n const inlineStartPadding: string = hasStartIcon\n ? `calc(${theme.vars.spacing.unit} * 5)`\n : `calc(${theme.vars.spacing.unit} * 1.5)`;\n const inlineEndPadding: string = hasEndIcon\n ? `calc(${theme.vars.spacing.unit} * 5)`\n : `calc(${theme.vars.spacing.unit} * 1.5)`;\n\n const inputContainer: string = css`\n position: relative;\n display: flex;\n align-items: center;\n `;\n\n const input: string = css`\n width: 100%;\n padding-block: ${theme.vars.spacing.unit};\n padding-inline-start: ${inlineStartPadding};\n padding-inline-end: ${inlineEndPadding};\n border: 1px solid ${hasError ? theme.vars.colors.error.main : theme.vars.colors.border};\n border-radius: ${theme.vars.components?.Field?.root?.borderRadius || theme.vars.borderRadius.medium};\n font-size: ${theme.vars.typography.fontSizes.md};\n font-family: ${theme.vars.typography.fontFamily};\n color: ${theme.vars.colors.text.primary};\n background-color: ${disabled ? theme.vars.colors.background.disabled : theme.vars.colors.background.surface};\n outline: none;\n transition:\n border-color 0.2s ease,\n box-shadow 0.2s ease;\n\n &:focus {\n border-color: ${hasError ? theme.vars.colors.error.main : theme.vars.colors.primary.main};\n box-shadow: 0 0 0 2px ${hasError ? `${theme.vars.colors.error.main}20` : `${theme.vars.colors.primary.main}20`};\n }\n\n &:disabled {\n opacity: 0.6;\n cursor: not-allowed;\n }\n\n &:hover:not(:disabled) {\n border-color: ${hasError ? theme.vars.colors.error.main : theme.vars.colors.primary.main};\n }\n\n &::placeholder {\n color: ${theme.vars.colors.text.secondary};\n opacity: 0.7;\n }\n `;\n\n const inputError: string = css`\n border-color: ${theme.vars.colors.error.main};\n\n &:focus {\n border-color: ${theme.vars.colors.error.main};\n box-shadow: 0 0 0 2px ${theme.vars.colors.error.main}20;\n }\n\n &:hover:not(:disabled) {\n border-color: ${theme.vars.colors.error.main};\n }\n `;\n\n const inputDisabled: string = css`\n background-color: ${theme.vars.colors.background.disabled};\n opacity: 0.6;\n cursor: not-allowed;\n `;\n\n const icon: string = css`\n position: absolute;\n background: none;\n border: none;\n cursor: ${disabled ? 'not-allowed' : 'pointer'};\n padding: calc(${theme.vars.spacing.unit} / 2);\n display: flex;\n align-items: center;\n justify-content: center;\n color: ${theme.vars.colors.text.secondary};\n opacity: ${disabled ? 0.5 : 1};\n top: 50%;\n transform: translateY(-50%);\n transition:\n color 0.2s ease,\n opacity 0.2s ease;\n\n &:hover:not(:disabled) {\n color: ${theme.vars.colors.text.primary};\n }\n\n &:focus {\n outline: 2px solid ${theme.vars.colors.primary.main};\n outline-offset: 2px;\n }\n `;\n\n const startIcon: string = css`\n ${icon};\n inset-inline-start: ${theme.vars.spacing.unit};\n `;\n\n const endIcon: string = css`\n ${icon};\n inset-inline-end: ${theme.vars.spacing.unit};\n `;\n\n return {\n endIcon,\n icon,\n input,\n inputContainer,\n inputDisabled,\n inputError,\n startIcon,\n };\n }, [theme, colorScheme, disabled, hasError, hasStartIcon, hasEndIcon]);\n\nexport default useStyles;\n"],"mappings":";;;;;;;;;;;;;;;;;AAiBA,MAAM,aACJ,OACA,aACA,UACA,UACA,cACA,wCAEc;CACZ,MAAMA,qBAA6B,eAC/B,QAAQ,MAAM,KAAK,QAAQ,KAAK,SAChC,QAAQ,MAAM,KAAK,QAAQ,KAAK;CACpC,MAAMC,mBAA2B,aAC7B,QAAQ,MAAM,KAAK,QAAQ,KAAK,SAChC,QAAQ,MAAM,KAAK,QAAQ,KAAK;CAEpC,MAAMC,iBAAyB,iBAAG;;;;;CAMlC,MAAMC,QAAgB,iBAAG;;uBAEN,MAAM,KAAK,QAAQ,KAAK;8BACjB,mBAAmB;4BACrB,iBAAiB;0BACnB,WAAW,MAAM,KAAK,OAAO,MAAM,OAAO,MAAM,KAAK,OAAO,OAAO;uBACtE,MAAM,KAAK,YAAY,OAAO,MAAM,gBAAgB,MAAM,KAAK,aAAa,OAAO;mBACvF,MAAM,KAAK,WAAW,UAAU,GAAG;qBACjC,MAAM,KAAK,WAAW,WAAW;eACvC,MAAM,KAAK,OAAO,KAAK,QAAQ;0BACpB,WAAW,MAAM,KAAK,OAAO,WAAW,WAAW,MAAM,KAAK,OAAO,WAAW,QAAQ;;;;;;;wBAO1F,WAAW,MAAM,KAAK,OAAO,MAAM,OAAO,MAAM,KAAK,OAAO,QAAQ,KAAK;gCACjE,WAAW,GAAG,MAAM,KAAK,OAAO,MAAM,KAAK,MAAM,GAAG,MAAM,KAAK,OAAO,QAAQ,KAAK,IAAI;;;;;;;;;wBAS/F,WAAW,MAAM,KAAK,OAAO,MAAM,OAAO,MAAM,KAAK,OAAO,QAAQ,KAAK;;;;iBAIhF,MAAM,KAAK,OAAO,KAAK,UAAU;;;;CAK9C,MAAMC,aAAqB,iBAAG;sBACZ,MAAM,KAAK,OAAO,MAAM,KAAK;;;wBAG3B,MAAM,KAAK,OAAO,MAAM,KAAK;gCACrB,MAAM,KAAK,OAAO,MAAM,KAAK;;;;wBAIrC,MAAM,KAAK,OAAO,MAAM,KAAK;;;CAIjD,MAAMC,gBAAwB,iBAAG;0BACX,MAAM,KAAK,OAAO,WAAW,SAAS;;;;CAK5D,MAAMC,OAAe,iBAAG;;;;gBAIZ,WAAW,gBAAgB,UAAU;sBAC/B,MAAM,KAAK,QAAQ,KAAK;;;;eAI/B,MAAM,KAAK,OAAO,KAAK,UAAU;iBAC/B,WAAW,KAAM,EAAE;;;;;;;;iBAQnB,MAAM,KAAK,OAAO,KAAK,QAAQ;;;;6BAInB,MAAM,KAAK,OAAO,QAAQ,KAAK;;;;CAKxD,MAAMC,YAAoB,iBAAG;QACzB,KAAK;4BACe,MAAM,KAAK,QAAQ,KAAK;;AAQhD,QAAO;EACL,SANsB,iBAAG;QACvB,KAAK;0BACa,MAAM,KAAK,QAAQ,KAAK;;EAK5C;EACA;EACA;EACA;EACA;EACA;EACD;GACA;CAAC;CAAO;CAAa;CAAU;CAAU;CAAc;CAAW,CAAC;AAExE,+BAAe"}
1
+ {"version":3,"file":"TextField.styles.cjs","names":["inlineStartPadding: string","inlineEndPadding: string","inputContainer: string","input: string","inputError: string","inputDisabled: string","icon: string","startIcon: string"],"sources":["../../../../../src/components/primitives/TextField/TextField.styles.ts"],"sourcesContent":["// Copyright 2024 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {Theme} from '@thunderid/browser';\nimport {useMemo} from 'react';\nimport {css} from '../../../styles/emotion';\n\n/**\n * Creates styles for the TextField component using BEM methodology\n * @param theme - The theme object containing design tokens\n * @param colorScheme - The current color scheme (used for memoization)\n * @param disabled - Whether the component is disabled\n * @param hasError - Whether the component has an error\n * @param hasStartIcon - Whether the component has a start icon\n * @param hasEndIcon - Whether the component has an end icon\n * @returns Object containing CSS class names for component styling\n */\nconst useStyles = (\n theme: Theme,\n colorScheme: string,\n disabled: boolean,\n hasError: boolean,\n hasStartIcon: boolean,\n hasEndIcon: boolean,\n): Record<string, string> =>\n useMemo(() => {\n const inlineStartPadding: string = hasStartIcon\n ? `calc(${theme.vars.spacing.unit} * 5)`\n : `calc(${theme.vars.spacing.unit} * 1.5)`;\n const inlineEndPadding: string = hasEndIcon\n ? `calc(${theme.vars.spacing.unit} * 5)`\n : `calc(${theme.vars.spacing.unit} * 1.5)`;\n\n const inputContainer: string = css`\n position: relative;\n display: flex;\n align-items: center;\n `;\n\n const input: string = css`\n width: 100%;\n padding-block: ${theme.vars.spacing.unit};\n padding-inline-start: ${inlineStartPadding};\n padding-inline-end: ${inlineEndPadding};\n border: 1px solid ${hasError ? theme.vars.colors.error.main : theme.vars.colors.border};\n border-radius: ${theme.vars.components?.Field?.root?.borderRadius || theme.vars.borderRadius.medium};\n font-size: ${theme.vars.typography.fontSizes.md};\n font-family: ${theme.vars.typography.fontFamily};\n color: ${theme.vars.colors.text.primary};\n background-color: ${disabled ? theme.vars.colors.background.disabled : theme.vars.colors.background.surface};\n outline: none;\n transition:\n border-color 0.2s ease,\n box-shadow 0.2s ease;\n\n &:focus {\n border-color: ${hasError ? theme.vars.colors.error.main : theme.vars.colors.primary.main};\n box-shadow: 0 0 0 2px ${hasError ? `${theme.vars.colors.error.main}20` : `${theme.vars.colors.primary.main}20`};\n }\n\n &:disabled {\n opacity: 0.6;\n cursor: not-allowed;\n }\n\n &:hover:not(:disabled) {\n border-color: ${hasError ? theme.vars.colors.error.main : theme.vars.colors.primary.main};\n }\n\n &::placeholder {\n color: ${theme.vars.colors.text.secondary};\n opacity: 0.7;\n }\n `;\n\n const inputError: string = css`\n border-color: ${theme.vars.colors.error.main};\n\n &:focus {\n border-color: ${theme.vars.colors.error.main};\n box-shadow: 0 0 0 2px ${theme.vars.colors.error.main}20;\n }\n\n &:hover:not(:disabled) {\n border-color: ${theme.vars.colors.error.main};\n }\n `;\n\n const inputDisabled: string = css`\n background-color: ${theme.vars.colors.background.disabled};\n opacity: 0.6;\n cursor: not-allowed;\n `;\n\n const icon: string = css`\n position: absolute;\n background: none;\n border: none;\n cursor: ${disabled ? 'not-allowed' : 'pointer'};\n padding: calc(${theme.vars.spacing.unit} / 2);\n display: flex;\n align-items: center;\n justify-content: center;\n color: ${theme.vars.colors.text.secondary};\n opacity: ${disabled ? 0.5 : 1};\n top: 50%;\n transform: translateY(-50%);\n transition:\n color 0.2s ease,\n opacity 0.2s ease;\n\n &:hover:not(:disabled) {\n color: ${theme.vars.colors.text.primary};\n }\n\n &:focus {\n outline: 2px solid ${theme.vars.colors.primary.main};\n outline-offset: 2px;\n }\n `;\n\n const startIcon: string = css`\n ${icon};\n inset-inline-start: ${theme.vars.spacing.unit};\n `;\n\n const endIcon: string = css`\n ${icon};\n inset-inline-end: ${theme.vars.spacing.unit};\n `;\n\n return {\n endIcon,\n icon,\n input,\n inputContainer,\n inputDisabled,\n inputError,\n startIcon,\n };\n }, [theme, colorScheme, disabled, hasError, hasStartIcon, hasEndIcon]);\n\nexport default useStyles;\n"],"mappings":";;;;;;;;;;;;;;;;AAiBA,MAAM,aACJ,OACA,aACA,UACA,UACA,cACA,wCAEc;CACZ,MAAMA,qBAA6B,eAC/B,QAAQ,MAAM,KAAK,QAAQ,KAAK,SAChC,QAAQ,MAAM,KAAK,QAAQ,KAAK;CACpC,MAAMC,mBAA2B,aAC7B,QAAQ,MAAM,KAAK,QAAQ,KAAK,SAChC,QAAQ,MAAM,KAAK,QAAQ,KAAK;CAEpC,MAAMC,iBAAyB,mBAAG;;;;;CAMlC,MAAMC,QAAgB,mBAAG;;uBAEN,MAAM,KAAK,QAAQ,KAAK;8BACjB,mBAAmB;4BACrB,iBAAiB;0BACnB,WAAW,MAAM,KAAK,OAAO,MAAM,OAAO,MAAM,KAAK,OAAO,OAAO;uBACtE,MAAM,KAAK,YAAY,OAAO,MAAM,gBAAgB,MAAM,KAAK,aAAa,OAAO;mBACvF,MAAM,KAAK,WAAW,UAAU,GAAG;qBACjC,MAAM,KAAK,WAAW,WAAW;eACvC,MAAM,KAAK,OAAO,KAAK,QAAQ;0BACpB,WAAW,MAAM,KAAK,OAAO,WAAW,WAAW,MAAM,KAAK,OAAO,WAAW,QAAQ;;;;;;;wBAO1F,WAAW,MAAM,KAAK,OAAO,MAAM,OAAO,MAAM,KAAK,OAAO,QAAQ,KAAK;gCACjE,WAAW,GAAG,MAAM,KAAK,OAAO,MAAM,KAAK,MAAM,GAAG,MAAM,KAAK,OAAO,QAAQ,KAAK,IAAI;;;;;;;;;wBAS/F,WAAW,MAAM,KAAK,OAAO,MAAM,OAAO,MAAM,KAAK,OAAO,QAAQ,KAAK;;;;iBAIhF,MAAM,KAAK,OAAO,KAAK,UAAU;;;;CAK9C,MAAMC,aAAqB,mBAAG;sBACZ,MAAM,KAAK,OAAO,MAAM,KAAK;;;wBAG3B,MAAM,KAAK,OAAO,MAAM,KAAK;gCACrB,MAAM,KAAK,OAAO,MAAM,KAAK;;;;wBAIrC,MAAM,KAAK,OAAO,MAAM,KAAK;;;CAIjD,MAAMC,gBAAwB,mBAAG;0BACX,MAAM,KAAK,OAAO,WAAW,SAAS;;;;CAK5D,MAAMC,OAAe,mBAAG;;;;gBAIZ,WAAW,gBAAgB,UAAU;sBAC/B,MAAM,KAAK,QAAQ,KAAK;;;;eAI/B,MAAM,KAAK,OAAO,KAAK,UAAU;iBAC/B,WAAW,KAAM,EAAE;;;;;;;;iBAQnB,MAAM,KAAK,OAAO,KAAK,QAAQ;;;;6BAInB,MAAM,KAAK,OAAO,QAAQ,KAAK;;;;CAKxD,MAAMC,YAAoB,mBAAG;QACzB,KAAK;4BACe,MAAM,KAAK,QAAQ,KAAK;;AAQhD,QAAO;EACL,SANsB,mBAAG;QACvB,KAAK;0BACa,MAAM,KAAK,QAAQ,KAAK;;EAK5C;EACA;EACA;EACA;EACA;EACA;EACD;GACA;CAAC;CAAO;CAAa;CAAU;CAAU;CAAc;CAAW,CAAC;AAExE,+BAAe"}
@@ -1,4 +1,5 @@
1
1
  const require_rolldown_runtime = require('../../../_virtual/rolldown_runtime.cjs');
2
+ const require_emotion = require('../../../styles/emotion.cjs');
2
3
  const require_useTheme = require('../../../contexts/Theme/useTheme.cjs');
3
4
  const require_Toggle_styles = require('./Toggle.styles.cjs');
4
5
  const require_FormControl = require('../FormControl/FormControl.cjs');
@@ -7,8 +8,6 @@ let __thunderid_browser = require("@thunderid/browser");
7
8
  __thunderid_browser = require_rolldown_runtime.__toESM(__thunderid_browser);
8
9
  let react_jsx_runtime = require("react/jsx-runtime");
9
10
  react_jsx_runtime = require_rolldown_runtime.__toESM(react_jsx_runtime);
10
- let __emotion_css = require("@emotion/css");
11
- __emotion_css = require_rolldown_runtime.__toESM(__emotion_css);
12
11
 
13
12
  //#region src/components/primitives/Toggle/Toggle.tsx
14
13
  /**
@@ -28,29 +27,29 @@ const Toggle = ({ label, error, className, required, helperText, style = {},...r
28
27
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_FormControl.default, {
29
28
  error,
30
29
  helperText,
31
- className: (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle")), className),
30
+ className: require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle")), className),
32
31
  helperTextMarginLeft: `calc(${theme.vars.spacing.unit} * 5.5)`,
33
32
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("label", {
34
33
  style,
35
- className: (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle", "container")), styles["container"]),
34
+ className: require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle", "container")), styles["container"]),
36
35
  children: [
37
36
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
38
37
  type: "checkbox",
39
38
  role: "switch",
40
- className: (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle", "input")), styles["input"]),
39
+ className: require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle", "input")), styles["input"]),
41
40
  "aria-invalid": hasError,
42
41
  "aria-required": required,
43
42
  ...rest
44
43
  }),
45
44
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
46
- className: (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle", "track")), styles["track"]),
47
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { className: (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle", "thumb")), styles["thumb"]) })
45
+ className: require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle", "track")), styles["track"]),
46
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { className: require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle", "thumb")), styles["thumb"]) })
48
47
  }),
49
48
  label && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_InputLabel.default, {
50
49
  required,
51
50
  error: hasError,
52
51
  variant: "inline",
53
- className: (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle", "label")), styles["label"], styles["errorLabel"], { [(0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle", "label", "error"))]: hasError }),
52
+ className: require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle", "label")), styles["label"], styles["errorLabel"], { [(0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("toggle", "label", "error"))]: hasError }),
54
53
  children: label
55
54
  })
56
55
  ]
@@ -1 +1 @@
1
- {"version":3,"file":"Toggle.cjs","names":["Toggle: FC<ToggleProps>","useTheme","styles: Record<string, string>","useStyles","FormControl","InputLabel"],"sources":["../../../../../src/components/primitives/Toggle/Toggle.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {cx} from '@emotion/css';\nimport {withVendorCSSClassPrefix, bem} from '@thunderid/browser';\nimport {FC, InputHTMLAttributes} from 'react';\nimport useStyles from './Toggle.styles';\nimport useTheme from '../../../contexts/Theme/useTheme';\nimport FormControl from '../FormControl/FormControl';\nimport InputLabel from '../InputLabel/InputLabel';\n\n/**\n * Props for the Toggle component.\n */\nexport interface ToggleProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'className' | 'type'> {\n className?: string;\n error?: string;\n helperText?: string;\n label?: string;\n required?: boolean;\n}\n\n/**\n * A Toggle component that represents a boolean input. It is built on top of a hidden checkbox input\n * and styled to look like a switch.\n *\n * The component is wrapped in a FormControl to display error messages and helper text.\n * The label is associated with the input for accessibility.\n *\n * @param props - Props for the Toggle component\n * @returns A JSX element representing the Toggle\n */\nconst Toggle: FC<ToggleProps> = ({label, error, className, required, helperText, style = {}, ...rest}: ToggleProps) => {\n const {theme, colorScheme}: ReturnType<typeof useTheme> = useTheme();\n const hasError = !!error;\n const styles: Record<string, string> = useStyles(theme, colorScheme, hasError, !!required);\n\n return (\n <FormControl\n error={error}\n helperText={helperText}\n className={cx(withVendorCSSClassPrefix(bem('toggle')), className)}\n helperTextMarginLeft={`calc(${theme.vars.spacing.unit} * 5.5)`}\n >\n <label style={style} className={cx(withVendorCSSClassPrefix(bem('toggle', 'container')), styles['container'])}>\n <input\n type=\"checkbox\"\n role=\"switch\"\n className={cx(withVendorCSSClassPrefix(bem('toggle', 'input')), styles['input'])}\n aria-invalid={hasError}\n aria-required={required}\n {...rest}\n />\n <div className={cx(withVendorCSSClassPrefix(bem('toggle', 'track')), styles['track'])}>\n <span className={cx(withVendorCSSClassPrefix(bem('toggle', 'thumb')), styles['thumb'])} />\n </div>\n {label && (\n <InputLabel\n required={required}\n error={hasError}\n variant=\"inline\"\n className={cx(withVendorCSSClassPrefix(bem('toggle', 'label')), styles['label'], styles['errorLabel'], {\n [withVendorCSSClassPrefix(bem('toggle', 'label', 'error'))]: hasError,\n })}\n >\n {label}\n </InputLabel>\n )}\n </label>\n </FormControl>\n );\n};\n\nexport default Toggle;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAgCA,MAAMA,UAA2B,EAAC,OAAO,OAAO,WAAW,UAAU,YAAY,QAAQ,EAAE,CAAE,GAAG,WAAuB;CACrH,MAAM,EAAC,OAAO,gBAA4CC,0BAAU;CACpE,MAAM,WAAW,CAAC,CAAC;CACnB,MAAMC,SAAiCC,8BAAU,OAAO,aAAa,UAAU,CAAC,CAAC,SAAS;AAE1F,QACE,2CAACC;EACQ;EACK;EACZ,gHAA2C,SAAS,CAAC,EAAE,UAAU;EACjE,sBAAsB,QAAQ,MAAM,KAAK,QAAQ,KAAK;YAEtD,4CAAC;GAAa;GAAO,gHAA2C,UAAU,YAAY,CAAC,EAAE,OAAO,aAAa;;IAC3G,2CAAC;KACC,MAAK;KACL,MAAK;KACL,gHAA2C,UAAU,QAAQ,CAAC,EAAE,OAAO,SAAS;KAChF,gBAAc;KACd,iBAAe;KACf,GAAI;MACJ;IACF,2CAAC;KAAI,gHAA2C,UAAU,QAAQ,CAAC,EAAE,OAAO,SAAS;eACnF,2CAAC,UAAK,gHAA2C,UAAU,QAAQ,CAAC,EAAE,OAAO,SAAS,GAAI;MACtF;IACL,SACC,2CAACC;KACW;KACV,OAAO;KACP,SAAQ;KACR,gHAA2C,UAAU,QAAQ,CAAC,EAAE,OAAO,UAAU,OAAO,eAAe,kFACvE,UAAU,SAAS,QAAQ,CAAC,GAAG,UAC9D,CAAC;eAED;MACU;;IAET;GACI;;AAIlB,qBAAe"}
1
+ {"version":3,"file":"Toggle.cjs","names":["Toggle: FC<ToggleProps>","useTheme","styles: Record<string, string>","useStyles","FormControl","cx","InputLabel"],"sources":["../../../../../src/components/primitives/Toggle/Toggle.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {withVendorCSSClassPrefix, bem} from '@thunderid/browser';\nimport {FC, InputHTMLAttributes} from 'react';\nimport useStyles from './Toggle.styles';\nimport useTheme from '../../../contexts/Theme/useTheme';\nimport {cx} from '../../../styles/emotion';\nimport FormControl from '../FormControl/FormControl';\nimport InputLabel from '../InputLabel/InputLabel';\n\n/**\n * Props for the Toggle component.\n */\nexport interface ToggleProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'className' | 'type'> {\n className?: string;\n error?: string;\n helperText?: string;\n label?: string;\n required?: boolean;\n}\n\n/**\n * A Toggle component that represents a boolean input. It is built on top of a hidden checkbox input\n * and styled to look like a switch.\n *\n * The component is wrapped in a FormControl to display error messages and helper text.\n * The label is associated with the input for accessibility.\n *\n * @param props - Props for the Toggle component\n * @returns A JSX element representing the Toggle\n */\nconst Toggle: FC<ToggleProps> = ({label, error, className, required, helperText, style = {}, ...rest}: ToggleProps) => {\n const {theme, colorScheme}: ReturnType<typeof useTheme> = useTheme();\n const hasError = !!error;\n const styles: Record<string, string> = useStyles(theme, colorScheme, hasError, !!required);\n\n return (\n <FormControl\n error={error}\n helperText={helperText}\n className={cx(withVendorCSSClassPrefix(bem('toggle')), className)}\n helperTextMarginLeft={`calc(${theme.vars.spacing.unit} * 5.5)`}\n >\n <label style={style} className={cx(withVendorCSSClassPrefix(bem('toggle', 'container')), styles['container'])}>\n <input\n type=\"checkbox\"\n role=\"switch\"\n className={cx(withVendorCSSClassPrefix(bem('toggle', 'input')), styles['input'])}\n aria-invalid={hasError}\n aria-required={required}\n {...rest}\n />\n <div className={cx(withVendorCSSClassPrefix(bem('toggle', 'track')), styles['track'])}>\n <span className={cx(withVendorCSSClassPrefix(bem('toggle', 'thumb')), styles['thumb'])} />\n </div>\n {label && (\n <InputLabel\n required={required}\n error={hasError}\n variant=\"inline\"\n className={cx(withVendorCSSClassPrefix(bem('toggle', 'label')), styles['label'], styles['errorLabel'], {\n [withVendorCSSClassPrefix(bem('toggle', 'label', 'error'))]: hasError,\n })}\n >\n {label}\n </InputLabel>\n )}\n </label>\n </FormControl>\n );\n};\n\nexport default Toggle;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAgCA,MAAMA,UAA2B,EAAC,OAAO,OAAO,WAAW,UAAU,YAAY,QAAQ,EAAE,CAAE,GAAG,WAAuB;CACrH,MAAM,EAAC,OAAO,gBAA4CC,0BAAU;CACpE,MAAM,WAAW,CAAC,CAAC;CACnB,MAAMC,SAAiCC,8BAAU,OAAO,aAAa,UAAU,CAAC,CAAC,SAAS;AAE1F,QACE,2CAACC;EACQ;EACK;EACZ,WAAWC,kGAAgC,SAAS,CAAC,EAAE,UAAU;EACjE,sBAAsB,QAAQ,MAAM,KAAK,QAAQ,KAAK;YAEtD,4CAAC;GAAa;GAAO,WAAWA,kGAAgC,UAAU,YAAY,CAAC,EAAE,OAAO,aAAa;;IAC3G,2CAAC;KACC,MAAK;KACL,MAAK;KACL,WAAWA,kGAAgC,UAAU,QAAQ,CAAC,EAAE,OAAO,SAAS;KAChF,gBAAc;KACd,iBAAe;KACf,GAAI;MACJ;IACF,2CAAC;KAAI,WAAWA,kGAAgC,UAAU,QAAQ,CAAC,EAAE,OAAO,SAAS;eACnF,2CAAC,UAAK,WAAWA,kGAAgC,UAAU,QAAQ,CAAC,EAAE,OAAO,SAAS,GAAI;MACtF;IACL,SACC,2CAACC;KACW;KACV,OAAO;KACP,SAAQ;KACR,WAAWD,kGAAgC,UAAU,QAAQ,CAAC,EAAE,OAAO,UAAU,OAAO,eAAe,kFACvE,UAAU,SAAS,QAAQ,CAAC,GAAG,UAC9D,CAAC;eAED;MACU;;IAET;GACI;;AAIlB,qBAAe"}
@@ -1,17 +1,16 @@
1
1
  const require_rolldown_runtime = require('../../../_virtual/rolldown_runtime.cjs');
2
+ const require_emotion = require('../../../styles/emotion.cjs');
2
3
  let react = require("react");
3
4
  react = require_rolldown_runtime.__toESM(react);
4
- let __emotion_css = require("@emotion/css");
5
- __emotion_css = require_rolldown_runtime.__toESM(__emotion_css);
6
5
 
7
6
  //#region src/components/primitives/Toggle/Toggle.styles.ts
8
7
  const useStyles = (theme, colorScheme, hasError, required) => (0, react.useMemo)(() => {
9
- const containerStyles = __emotion_css.css`
8
+ const containerStyles = require_emotion.css`
10
9
  display: inline-flex;
11
10
  align-items: center;
12
11
  cursor: pointer;
13
12
  `;
14
- const inputStyles = __emotion_css.css`
13
+ const inputStyles = require_emotion.css`
15
14
  border: 0;
16
15
  clip: rect(0 0 0 0);
17
16
  height: 1px;
@@ -32,7 +31,7 @@ const useStyles = (theme, colorScheme, hasError, required) => (0, react.useMemo)
32
31
  opacity: 0.6;
33
32
  }
34
33
  `;
35
- const trackStyles = __emotion_css.css`
34
+ const trackStyles = require_emotion.css`
36
35
  position: relative;
37
36
  display: inline-flex;
38
37
  align-items: center;
@@ -52,7 +51,7 @@ const useStyles = (theme, colorScheme, hasError, required) => (0, react.useMemo)
52
51
  opacity: 0.4;
53
52
  }
54
53
  `;
55
- const thumbStyles = __emotion_css.css`
54
+ const thumbStyles = require_emotion.css`
56
55
  position: absolute;
57
56
  left: 2px;
58
57
  width: 16px;
@@ -65,7 +64,7 @@ const useStyles = (theme, colorScheme, hasError, required) => (0, react.useMemo)
65
64
  transform: translateX(16px);
66
65
  }
67
66
  `;
68
- const labelStyles = __emotion_css.css`
67
+ const labelStyles = require_emotion.css`
69
68
  margin-left: calc(${theme.vars.spacing.unit} * 1.5);
70
69
  color: ${theme.vars.colors.text.primary};
71
70
  font-size: ${theme.vars.typography.fontSizes.sm};
@@ -77,7 +76,7 @@ const useStyles = (theme, colorScheme, hasError, required) => (0, react.useMemo)
77
76
  opacity: 0.6;
78
77
  }
79
78
  `;
80
- const errorLabelStyles = __emotion_css.css`
79
+ const errorLabelStyles = require_emotion.css`
81
80
  color: ${theme.vars.colors.error.main};
82
81
  `;
83
82
  return {
@@ -1 +1 @@
1
- {"version":3,"file":"Toggle.styles.cjs","names":["containerStyles: string","inputStyles: string","trackStyles: string","thumbStyles: string","labelStyles: string","errorLabelStyles: string"],"sources":["../../../../../src/components/primitives/Toggle/Toggle.styles.ts"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {css} from '@emotion/css';\nimport {Theme} from '@thunderid/browser';\nimport {useMemo} from 'react';\n\nconst useStyles = (theme: Theme, colorScheme: string, hasError: boolean, required: boolean): Record<string, string> =>\n useMemo(() => {\n const containerStyles: string = css`\n display: inline-flex;\n align-items: center;\n cursor: pointer;\n `;\n\n const inputStyles: string = css`\n border: 0;\n clip: rect(0 0 0 0);\n height: 1px;\n margin: -1px;\n overflow: hidden;\n padding: 0;\n position: absolute;\n width: 1px;\n white-space: nowrap;\n\n &:focus-visible + div {\n outline: 2px solid ${theme.vars.colors.primary.main};\n outline-offset: 2px;\n }\n\n &:disabled + div {\n cursor: not-allowed;\n opacity: 0.6;\n }\n `;\n\n const trackStyles: string = css`\n position: relative;\n display: inline-flex;\n align-items: center;\n width: 36px;\n height: 20px;\n background-color: ${theme.vars.colors.text.secondary};\n opacity: 0.2;\n border-radius: 9999px;\n transition: all 0.2s ease-in-out;\n\n input:checked + & {\n background-color: ${theme.vars.colors.primary.main};\n opacity: 1;\n }\n\n input:disabled + & {\n opacity: 0.4;\n }\n `;\n\n const thumbStyles: string = css`\n position: absolute;\n left: 2px;\n width: 16px;\n height: 16px;\n background-color: #fff;\n border-radius: 50%;\n transition: transform 0.2s ease-in-out;\n\n input:checked + * > & {\n transform: translateX(16px);\n }\n `;\n\n const labelStyles: string = css`\n margin-left: calc(${theme.vars.spacing.unit} * 1.5);\n color: ${theme.vars.colors.text.primary};\n font-size: ${theme.vars.typography.fontSizes.sm};\n font-family: ${theme.vars.typography.fontFamily};\n cursor: pointer;\n\n input:disabled ~ & {\n cursor: not-allowed;\n opacity: 0.6;\n }\n `;\n\n const errorLabelStyles: string = css`\n color: ${theme.vars.colors.error.main};\n `;\n\n return {\n container: containerStyles,\n errorLabel: hasError ? errorLabelStyles : '',\n input: inputStyles,\n label: labelStyles,\n thumb: thumbStyles,\n track: trackStyles,\n };\n }, [theme, colorScheme, hasError, required]);\n\nexport default useStyles;\n"],"mappings":";;;;;;;AAOA,MAAM,aAAa,OAAc,aAAqB,UAAmB,sCACzD;CACZ,MAAMA,kBAA0B,iBAAG;;;;;CAMnC,MAAMC,cAAsB,iBAAG;;;;;;;;;;;;6BAYN,MAAM,KAAK,OAAO,QAAQ,KAAK;;;;;;;;;CAUxD,MAAMC,cAAsB,iBAAG;;;;;;0BAMT,MAAM,KAAK,OAAO,KAAK,UAAU;;;;;;4BAM/B,MAAM,KAAK,OAAO,QAAQ,KAAK;;;;;;;;CASvD,MAAMC,cAAsB,iBAAG;;;;;;;;;;;;;CAc/B,MAAMC,cAAsB,iBAAG;0BACT,MAAM,KAAK,QAAQ,KAAK;eACnC,MAAM,KAAK,OAAO,KAAK,QAAQ;mBAC3B,MAAM,KAAK,WAAW,UAAU,GAAG;qBACjC,MAAM,KAAK,WAAW,WAAW;;;;;;;;CASlD,MAAMC,mBAA2B,iBAAG;eACzB,MAAM,KAAK,OAAO,MAAM,KAAK;;AAGxC,QAAO;EACL,WAAW;EACX,YAAY,WAAW,mBAAmB;EAC1C,OAAO;EACP,OAAO;EACP,OAAO;EACP,OAAO;EACR;GACA;CAAC;CAAO;CAAa;CAAU;CAAS,CAAC;AAE9C,4BAAe"}
1
+ {"version":3,"file":"Toggle.styles.cjs","names":["containerStyles: string","inputStyles: string","trackStyles: string","thumbStyles: string","labelStyles: string","errorLabelStyles: string"],"sources":["../../../../../src/components/primitives/Toggle/Toggle.styles.ts"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {Theme} from '@thunderid/browser';\nimport {useMemo} from 'react';\nimport {css} from '../../../styles/emotion';\n\nconst useStyles = (theme: Theme, colorScheme: string, hasError: boolean, required: boolean): Record<string, string> =>\n useMemo(() => {\n const containerStyles: string = css`\n display: inline-flex;\n align-items: center;\n cursor: pointer;\n `;\n\n const inputStyles: string = css`\n border: 0;\n clip: rect(0 0 0 0);\n height: 1px;\n margin: -1px;\n overflow: hidden;\n padding: 0;\n position: absolute;\n width: 1px;\n white-space: nowrap;\n\n &:focus-visible + div {\n outline: 2px solid ${theme.vars.colors.primary.main};\n outline-offset: 2px;\n }\n\n &:disabled + div {\n cursor: not-allowed;\n opacity: 0.6;\n }\n `;\n\n const trackStyles: string = css`\n position: relative;\n display: inline-flex;\n align-items: center;\n width: 36px;\n height: 20px;\n background-color: ${theme.vars.colors.text.secondary};\n opacity: 0.2;\n border-radius: 9999px;\n transition: all 0.2s ease-in-out;\n\n input:checked + & {\n background-color: ${theme.vars.colors.primary.main};\n opacity: 1;\n }\n\n input:disabled + & {\n opacity: 0.4;\n }\n `;\n\n const thumbStyles: string = css`\n position: absolute;\n left: 2px;\n width: 16px;\n height: 16px;\n background-color: #fff;\n border-radius: 50%;\n transition: transform 0.2s ease-in-out;\n\n input:checked + * > & {\n transform: translateX(16px);\n }\n `;\n\n const labelStyles: string = css`\n margin-left: calc(${theme.vars.spacing.unit} * 1.5);\n color: ${theme.vars.colors.text.primary};\n font-size: ${theme.vars.typography.fontSizes.sm};\n font-family: ${theme.vars.typography.fontFamily};\n cursor: pointer;\n\n input:disabled ~ & {\n cursor: not-allowed;\n opacity: 0.6;\n }\n `;\n\n const errorLabelStyles: string = css`\n color: ${theme.vars.colors.error.main};\n `;\n\n return {\n container: containerStyles,\n errorLabel: hasError ? errorLabelStyles : '',\n input: inputStyles,\n label: labelStyles,\n thumb: thumbStyles,\n track: trackStyles,\n };\n }, [theme, colorScheme, hasError, required]);\n\nexport default useStyles;\n"],"mappings":";;;;;;AAOA,MAAM,aAAa,OAAc,aAAqB,UAAmB,sCACzD;CACZ,MAAMA,kBAA0B,mBAAG;;;;;CAMnC,MAAMC,cAAsB,mBAAG;;;;;;;;;;;;6BAYN,MAAM,KAAK,OAAO,QAAQ,KAAK;;;;;;;;;CAUxD,MAAMC,cAAsB,mBAAG;;;;;;0BAMT,MAAM,KAAK,OAAO,KAAK,UAAU;;;;;;4BAM/B,MAAM,KAAK,OAAO,QAAQ,KAAK;;;;;;;;CASvD,MAAMC,cAAsB,mBAAG;;;;;;;;;;;;;CAc/B,MAAMC,cAAsB,mBAAG;0BACT,MAAM,KAAK,QAAQ,KAAK;eACnC,MAAM,KAAK,OAAO,KAAK,QAAQ;mBAC3B,MAAM,KAAK,WAAW,UAAU,GAAG;qBACjC,MAAM,KAAK,WAAW,WAAW;;;;;;;;CASlD,MAAMC,mBAA2B,mBAAG;eACzB,MAAM,KAAK,OAAO,MAAM,KAAK;;AAGxC,QAAO;EACL,WAAW;EACX,YAAY,WAAW,mBAAmB;EAC1C,OAAO;EACP,OAAO;EACP,OAAO;EACP,OAAO;EACR;GACA;CAAC;CAAO;CAAa;CAAU;CAAS,CAAC;AAE9C,4BAAe"}
@@ -1,4 +1,5 @@
1
1
  const require_rolldown_runtime = require('../../../_virtual/rolldown_runtime.cjs');
2
+ const require_emotion = require('../../../styles/emotion.cjs');
2
3
  const require_useTheme = require('../../../contexts/Theme/useTheme.cjs');
3
4
  const require_Tooltip_styles = require('./Tooltip.styles.cjs');
4
5
  let __thunderid_browser = require("@thunderid/browser");
@@ -7,8 +8,6 @@ let react = require("react");
7
8
  react = require_rolldown_runtime.__toESM(react);
8
9
  let react_jsx_runtime = require("react/jsx-runtime");
9
10
  react_jsx_runtime = require_rolldown_runtime.__toESM(react_jsx_runtime);
10
- let __emotion_css = require("@emotion/css");
11
- __emotion_css = require_rolldown_runtime.__toESM(__emotion_css);
12
11
 
13
12
  //#region src/components/primitives/Tooltip/Tooltip.tsx
14
13
  /**
@@ -37,7 +36,7 @@ const Tooltip = ({ className = "", helperText = "", style = {}, position = "bott
37
36
  role: "button",
38
37
  "aria-label": ariaLabel,
39
38
  "aria-describedby": isVisible && helperText ? tooltipId : void 0,
40
- className: (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("tooltip", "container")), className, styles["container"]),
39
+ className: require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("tooltip", "container")), className, styles["container"]),
41
40
  style,
42
41
  onMouseEnter: () => setIsVisible(true),
43
42
  onMouseLeave: () => setIsVisible(false),
@@ -48,8 +47,8 @@ const Tooltip = ({ className = "", helperText = "", style = {}, position = "bott
48
47
  children: [children, isVisible && helperText && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
49
48
  id: tooltipId,
50
49
  role: "tooltip",
51
- className: (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("tooltip", "box")), (0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("tooltip", position)), styles["box"], styles[position || "bottom"]),
52
- children: [helperText, /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { className: (0, __emotion_css.cx)((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("tooltip", "arrow")), styles["arrow"], styles[`${position}-arrow`]) })]
50
+ className: require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("tooltip", "box")), (0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("tooltip", position)), styles["box"], styles[position || "bottom"]),
51
+ children: [helperText, /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { className: require_emotion.cx((0, __thunderid_browser.withVendorCSSClassPrefix)((0, __thunderid_browser.bem)("tooltip", "arrow")), styles["arrow"], styles[`${position}-arrow`]) })]
53
52
  })]
54
53
  });
55
54
  };
@@ -1 +1 @@
1
- {"version":3,"file":"Tooltip.cjs","names":["Tooltip: FC<Tooltiprops>","useTheme","styles: Record<string, string>","useStyles"],"sources":["../../../../../src/components/primitives/Tooltip/Tooltip.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {cx} from '@emotion/css';\nimport {withVendorCSSClassPrefix, bem} from '@thunderid/browser';\nimport {FC, InputHTMLAttributes, ReactNode, useId, useState, KeyboardEvent} from 'react';\nimport useStyles from './Tooltip.styles';\nimport useTheme from '../../../contexts/Theme/useTheme';\n\n/**\n * Props for the Tooltip component.\n */\nexport interface Tooltiprops extends Omit<InputHTMLAttributes<HTMLInputElement>, 'className' | 'type'> {\n className?: string;\n helperText?: string;\n position?: 'top' | 'bottom' | 'left' | 'right';\n children?: ReactNode;\n ariaLabel?: string;\n}\n\n/**\n * A Tooltip component that convert any react or html element to a tooltip.\n * When a user hover on it, they will see a small tooltip with some info.\n *\n * It will take a children, which can be a react element or html element.\n *\n * @param props - Props for the Tooltip component\n * @returns A JSX element representing the Tooltip\n */\nconst Tooltip: FC<Tooltiprops> = ({\n className = '',\n helperText = '',\n style = {},\n position = 'bottom',\n children = null,\n ariaLabel = 'More Info',\n ...rest\n}: Tooltiprops) => {\n const {theme, colorScheme}: ReturnType<typeof useTheme> = useTheme();\n const styles: Record<string, string> = useStyles(theme, colorScheme);\n const [isVisible, setIsVisible] = useState<boolean>(false);\n\n // Unique ID to connect trigger button to tooltip box via ARIA\n const tooltipId = useId();\n\n // Close tooltip if user presses ESC while focused\n const handleKeyDown = (e: KeyboardEvent<HTMLDivElement>) => {\n if (e.key === 'Escape' && isVisible) {\n setIsVisible(false);\n }\n\n // Optional: Prevent Space key from scrolling the page\n if (e.key === ' ' || e.key === 'Enter') {\n e.preventDefault();\n setIsVisible((prev) => !prev);\n }\n };\n return (\n <div\n tabIndex={0}\n role=\"button\"\n aria-label={ariaLabel}\n aria-describedby={isVisible && helperText ? tooltipId : undefined}\n className={cx(withVendorCSSClassPrefix(bem('tooltip', 'container')), className, styles['container'])}\n style={style}\n onMouseEnter={() => setIsVisible(true)}\n onMouseLeave={() => setIsVisible(false)}\n onFocus={() => setIsVisible(true)} /* Trigger on Tab Focus */\n onBlur={() => setIsVisible(false)} /* Hide on Tab Blur */\n onKeyDown={handleKeyDown} /* Allow ESC to dismiss */\n {...rest}\n >\n {children}\n {isVisible && helperText && (\n <div\n id={tooltipId}\n role=\"tooltip\"\n className={cx(\n withVendorCSSClassPrefix(bem('tooltip', 'box')),\n withVendorCSSClassPrefix(bem('tooltip', position)),\n styles['box'],\n styles[position || 'bottom'],\n )}\n >\n {helperText}\n <span\n className={cx(\n withVendorCSSClassPrefix(bem('tooltip', 'arrow')),\n styles['arrow'],\n styles[`${position}-arrow`],\n )}\n />\n </div>\n )}\n </div>\n );\n};\n\nexport default Tooltip;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AA6BA,MAAMA,WAA4B,EAChC,YAAY,IACZ,aAAa,IACb,QAAQ,EAAE,EACV,WAAW,UACX,WAAW,MACX,YAAY,YACZ,GAAG,WACc;CACjB,MAAM,EAAC,OAAO,gBAA4CC,0BAAU;CACpE,MAAMC,SAAiCC,+BAAU,OAAO,YAAY;CACpE,MAAM,CAAC,WAAW,oCAAkC,MAAM;CAG1D,MAAM,8BAAmB;CAGzB,MAAM,iBAAiB,MAAqC;AAC1D,MAAI,EAAE,QAAQ,YAAY,UACxB,cAAa,MAAM;AAIrB,MAAI,EAAE,QAAQ,OAAO,EAAE,QAAQ,SAAS;AACtC,KAAE,gBAAgB;AAClB,iBAAc,SAAS,CAAC,KAAK;;;AAGjC,QACE,4CAAC;EACC,UAAU;EACV,MAAK;EACL,cAAY;EACZ,oBAAkB,aAAa,aAAa,YAAY;EACxD,gHAA2C,WAAW,YAAY,CAAC,EAAE,WAAW,OAAO,aAAa;EAC7F;EACP,oBAAoB,aAAa,KAAK;EACtC,oBAAoB,aAAa,MAAM;EACvC,eAAe,aAAa,KAAK;EACjC,cAAc,aAAa,MAAM;EACjC,WAAW;EACX,GAAI;aAEH,UACA,aAAa,cACZ,4CAAC;GACC,IAAI;GACJ,MAAK;GACL,gHAC+B,WAAW,MAAM,CAAC,iFAClB,WAAW,SAAS,CAAC,EAClD,OAAO,QACP,OAAO,YAAY,UACpB;cAEA,YACD,2CAAC,UACC,gHAC+B,WAAW,QAAQ,CAAC,EACjD,OAAO,UACP,OAAO,GAAG,SAAS,SACpB,GACD;IACE;GAEJ;;AAIV,sBAAe"}
1
+ {"version":3,"file":"Tooltip.cjs","names":["Tooltip: FC<Tooltiprops>","useTheme","styles: Record<string, string>","useStyles","cx"],"sources":["../../../../../src/components/primitives/Tooltip/Tooltip.tsx"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {withVendorCSSClassPrefix, bem} from '@thunderid/browser';\nimport {FC, InputHTMLAttributes, ReactNode, useId, useState, KeyboardEvent} from 'react';\nimport useStyles from './Tooltip.styles';\nimport useTheme from '../../../contexts/Theme/useTheme';\nimport {cx} from '../../../styles/emotion';\n\n/**\n * Props for the Tooltip component.\n */\nexport interface Tooltiprops extends Omit<InputHTMLAttributes<HTMLInputElement>, 'className' | 'type'> {\n className?: string;\n helperText?: string;\n position?: 'top' | 'bottom' | 'left' | 'right';\n children?: ReactNode;\n ariaLabel?: string;\n}\n\n/**\n * A Tooltip component that convert any react or html element to a tooltip.\n * When a user hover on it, they will see a small tooltip with some info.\n *\n * It will take a children, which can be a react element or html element.\n *\n * @param props - Props for the Tooltip component\n * @returns A JSX element representing the Tooltip\n */\nconst Tooltip: FC<Tooltiprops> = ({\n className = '',\n helperText = '',\n style = {},\n position = 'bottom',\n children = null,\n ariaLabel = 'More Info',\n ...rest\n}: Tooltiprops) => {\n const {theme, colorScheme}: ReturnType<typeof useTheme> = useTheme();\n const styles: Record<string, string> = useStyles(theme, colorScheme);\n const [isVisible, setIsVisible] = useState<boolean>(false);\n\n // Unique ID to connect trigger button to tooltip box via ARIA\n const tooltipId = useId();\n\n // Close tooltip if user presses ESC while focused\n const handleKeyDown = (e: KeyboardEvent<HTMLDivElement>) => {\n if (e.key === 'Escape' && isVisible) {\n setIsVisible(false);\n }\n\n // Optional: Prevent Space key from scrolling the page\n if (e.key === ' ' || e.key === 'Enter') {\n e.preventDefault();\n setIsVisible((prev) => !prev);\n }\n };\n return (\n <div\n tabIndex={0}\n role=\"button\"\n aria-label={ariaLabel}\n aria-describedby={isVisible && helperText ? tooltipId : undefined}\n className={cx(withVendorCSSClassPrefix(bem('tooltip', 'container')), className, styles['container'])}\n style={style}\n onMouseEnter={() => setIsVisible(true)}\n onMouseLeave={() => setIsVisible(false)}\n onFocus={() => setIsVisible(true)} /* Trigger on Tab Focus */\n onBlur={() => setIsVisible(false)} /* Hide on Tab Blur */\n onKeyDown={handleKeyDown} /* Allow ESC to dismiss */\n {...rest}\n >\n {children}\n {isVisible && helperText && (\n <div\n id={tooltipId}\n role=\"tooltip\"\n className={cx(\n withVendorCSSClassPrefix(bem('tooltip', 'box')),\n withVendorCSSClassPrefix(bem('tooltip', position)),\n styles['box'],\n styles[position || 'bottom'],\n )}\n >\n {helperText}\n <span\n className={cx(\n withVendorCSSClassPrefix(bem('tooltip', 'arrow')),\n styles['arrow'],\n styles[`${position}-arrow`],\n )}\n />\n </div>\n )}\n </div>\n );\n};\n\nexport default Tooltip;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;AA6BA,MAAMA,WAA4B,EAChC,YAAY,IACZ,aAAa,IACb,QAAQ,EAAE,EACV,WAAW,UACX,WAAW,MACX,YAAY,YACZ,GAAG,WACc;CACjB,MAAM,EAAC,OAAO,gBAA4CC,0BAAU;CACpE,MAAMC,SAAiCC,+BAAU,OAAO,YAAY;CACpE,MAAM,CAAC,WAAW,oCAAkC,MAAM;CAG1D,MAAM,8BAAmB;CAGzB,MAAM,iBAAiB,MAAqC;AAC1D,MAAI,EAAE,QAAQ,YAAY,UACxB,cAAa,MAAM;AAIrB,MAAI,EAAE,QAAQ,OAAO,EAAE,QAAQ,SAAS;AACtC,KAAE,gBAAgB;AAClB,iBAAc,SAAS,CAAC,KAAK;;;AAGjC,QACE,4CAAC;EACC,UAAU;EACV,MAAK;EACL,cAAY;EACZ,oBAAkB,aAAa,aAAa,YAAY;EACxD,WAAWC,kGAAgC,WAAW,YAAY,CAAC,EAAE,WAAW,OAAO,aAAa;EAC7F;EACP,oBAAoB,aAAa,KAAK;EACtC,oBAAoB,aAAa,MAAM;EACvC,eAAe,aAAa,KAAK;EACjC,cAAc,aAAa,MAAM;EACjC,WAAW;EACX,GAAI;aAEH,UACA,aAAa,cACZ,4CAAC;GACC,IAAI;GACJ,MAAK;GACL,WAAWA,kGACoB,WAAW,MAAM,CAAC,iFAClB,WAAW,SAAS,CAAC,EAClD,OAAO,QACP,OAAO,YAAY,UACpB;cAEA,YACD,2CAAC,UACC,WAAWA,kGACoB,WAAW,QAAQ,CAAC,EACjD,OAAO,UACP,OAAO,GAAG,SAAS,SACpB,GACD;IACE;GAEJ;;AAIV,sBAAe"}
@@ -1,20 +1,19 @@
1
1
  const require_rolldown_runtime = require('../../../_virtual/rolldown_runtime.cjs');
2
+ const require_emotion = require('../../../styles/emotion.cjs');
2
3
  let react = require("react");
3
4
  react = require_rolldown_runtime.__toESM(react);
4
- let __emotion_css = require("@emotion/css");
5
- __emotion_css = require_rolldown_runtime.__toESM(__emotion_css);
6
5
 
7
6
  //#region src/components/primitives/Tooltip/Tooltip.styles.ts
8
7
  const useStyles = (theme, colorScheme) => (0, react.useMemo)(() => {
9
- const fadeInAnimation = __emotion_css.keyframes`
8
+ const fadeInAnimation = require_emotion.keyframes`
10
9
  from { opacity: 0; }
11
10
  to { opacity: 1; }
12
11
  `;
13
- const containerStyles = __emotion_css.css`
12
+ const containerStyles = require_emotion.css`
14
13
  position: relative;
15
14
  display: inline-block;
16
15
  `;
17
- const boxStyles = __emotion_css.css`
16
+ const boxStyles = require_emotion.css`
18
17
  position: absolute;
19
18
  background-color: #333;
20
19
  color: #fff;
@@ -31,58 +30,58 @@ const useStyles = (theme, colorScheme) => (0, react.useMemo)(() => {
31
30
  overflow-wrap: break-word;
32
31
  text-align: start;
33
32
  `;
34
- const topStyles = __emotion_css.css`
33
+ const topStyles = require_emotion.css`
35
34
  bottom: 100%;
36
35
  left: 50%;
37
36
  transform: translateX(-50%);
38
37
  margin-bottom: 8px;
39
38
  `;
40
- const bottomStyles = __emotion_css.css`
39
+ const bottomStyles = require_emotion.css`
41
40
  top: 100%;
42
41
  left: 50%;
43
42
  transform: translateX(-50%);
44
43
  margin-top: 8px;
45
44
  `;
46
- const leftStyles = __emotion_css.css`
45
+ const leftStyles = require_emotion.css`
47
46
  right: 100%;
48
47
  top: 50%;
49
48
  transform: translateY(-50%);
50
49
  margin-right: 8px;
51
50
  `;
52
- const rightStyles = __emotion_css.css`
51
+ const rightStyles = require_emotion.css`
53
52
  left: 100%;
54
53
  top: 50%;
55
54
  transform: translateY(-50%);
56
55
  margin-left: 8px;
57
56
  `;
58
- const arrowStyles = __emotion_css.css`
57
+ const arrowStyles = require_emotion.css`
59
58
  position: absolute;
60
59
  width: 0;
61
60
  height: 0;
62
61
  border-style: solid;
63
62
  `;
64
- const topArrowStyles = __emotion_css.css`
63
+ const topArrowStyles = require_emotion.css`
65
64
  top: 100%;
66
65
  left: 50%;
67
66
  transform: translateX(-50%);
68
67
  border-width: 5px 5px 0 5px;
69
68
  border-color: #333 transparent transparent transparent;
70
69
  `;
71
- const bottomArrowStyles = __emotion_css.css`
70
+ const bottomArrowStyles = require_emotion.css`
72
71
  bottom: 100%;
73
72
  left: 50%;
74
73
  transform: translateX(-50%);
75
74
  border-width: 0 5px 5px 5px;
76
75
  border-color: transparent transparent #333 transparent;
77
76
  `;
78
- const leftArrowStyles = __emotion_css.css`
77
+ const leftArrowStyles = require_emotion.css`
79
78
  left: 100%;
80
79
  top: 50%;
81
80
  transform: translateY(-50%);
82
81
  border-width: 5px 0 5px 5px;
83
82
  border-color: transparent transparent transparent #333;
84
83
  `;
85
- const rightArrowStyles = __emotion_css.css`
84
+ const rightArrowStyles = require_emotion.css`
86
85
  right: 100%;
87
86
  top: 50%;
88
87
  transform: translateY(-50%);
@@ -1 +1 @@
1
- {"version":3,"file":"Tooltip.styles.cjs","names":["containerStyles: string","boxStyles: string","topStyles: string","bottomStyles: string","leftStyles: string","rightStyles: string","arrowStyles: string","topArrowStyles: string","bottomArrowStyles: string","leftArrowStyles: string","rightArrowStyles: string"],"sources":["../../../../../src/components/primitives/Tooltip/Tooltip.styles.ts"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {css, keyframes} from '@emotion/css';\nimport {Theme} from '@thunderid/browser';\nimport {useMemo} from 'react';\n\nconst useStyles = (theme: Theme, colorScheme: string): Record<string, string> =>\n useMemo(() => {\n const fadeInAnimation = keyframes`\n from { opacity: 0; }\n to { opacity: 1; }\n `;\n\n const containerStyles: string = css`\n position: relative;\n display: inline-block;\n `;\n\n // white-space: nowrap;\n const boxStyles: string = css`\n position: absolute;\n background-color: #333;\n color: #fff;\n padding: 6px 12px;\n border-radius: 6px;\n font-size: 0.85rem;\n z-index: 1000;\n box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.15);\n animation: ${fadeInAnimation} 0.15s ease-in-out;\n\n min-width: 250px;\n white-space: normal;\n word-break: break-word;\n overflow-wrap: break-word;\n text-align: start;\n `;\n\n const topStyles: string = css`\n bottom: 100%;\n left: 50%;\n transform: translateX(-50%);\n margin-bottom: 8px;\n `;\n\n const bottomStyles: string = css`\n top: 100%;\n left: 50%;\n transform: translateX(-50%);\n margin-top: 8px;\n `;\n\n const leftStyles: string = css`\n right: 100%;\n top: 50%;\n transform: translateY(-50%);\n margin-right: 8px;\n `;\n\n const rightStyles: string = css`\n left: 100%;\n top: 50%;\n transform: translateY(-50%);\n margin-left: 8px;\n `;\n\n const arrowStyles: string = css`\n position: absolute;\n width: 0;\n height: 0;\n border-style: solid;\n `;\n\n const topArrowStyles: string = css`\n top: 100%;\n left: 50%;\n transform: translateX(-50%);\n border-width: 5px 5px 0 5px;\n border-color: #333 transparent transparent transparent;\n `;\n\n const bottomArrowStyles: string = css`\n bottom: 100%;\n left: 50%;\n transform: translateX(-50%);\n border-width: 0 5px 5px 5px;\n border-color: transparent transparent #333 transparent;\n `;\n\n const leftArrowStyles: string = css`\n left: 100%;\n top: 50%;\n transform: translateY(-50%);\n border-width: 5px 0 5px 5px;\n border-color: transparent transparent transparent #333;\n `;\n\n const rightArrowStyles: string = css`\n right: 100%;\n top: 50%;\n transform: translateY(-50%);\n border-width: 5px 5px 5px 0;\n border-color: transparent #333 transparent transparent;\n `;\n\n return {\n container: containerStyles,\n box: boxStyles,\n top: topStyles,\n bottom: bottomStyles,\n left: leftStyles,\n right: rightStyles,\n arrow: arrowStyles,\n 'top-arrow': topArrowStyles,\n 'bottom-arrow': bottomArrowStyles,\n 'left-arrow': leftArrowStyles,\n 'right-arrow': rightArrowStyles,\n };\n }, [theme, colorScheme]);\n\nexport default useStyles;\n"],"mappings":";;;;;;;AAOA,MAAM,aAAa,OAAc,yCACjB;CACZ,MAAM,kBAAkB,uBAAS;;;;CAKjC,MAAMA,kBAA0B,iBAAG;;;;CAMnC,MAAMC,YAAoB,iBAAG;;;;;;;;;mBASd,gBAAgB;;;;;;;;CAS/B,MAAMC,YAAoB,iBAAG;;;;;;CAO7B,MAAMC,eAAuB,iBAAG;;;;;;CAOhC,MAAMC,aAAqB,iBAAG;;;;;;CAO9B,MAAMC,cAAsB,iBAAG;;;;;;CAO/B,MAAMC,cAAsB,iBAAG;;;;;;CAO/B,MAAMC,iBAAyB,iBAAG;;;;;;;CAQlC,MAAMC,oBAA4B,iBAAG;;;;;;;CAQrC,MAAMC,kBAA0B,iBAAG;;;;;;;CAQnC,MAAMC,mBAA2B,iBAAG;;;;;;;AAQpC,QAAO;EACL,WAAW;EACX,KAAK;EACL,KAAK;EACL,QAAQ;EACR,MAAM;EACN,OAAO;EACP,OAAO;EACP,aAAa;EACb,gBAAgB;EAChB,cAAc;EACd,eAAe;EAChB;GACA,CAAC,OAAO,YAAY,CAAC;AAE1B,6BAAe"}
1
+ {"version":3,"file":"Tooltip.styles.cjs","names":["containerStyles: string","boxStyles: string","topStyles: string","bottomStyles: string","leftStyles: string","rightStyles: string","arrowStyles: string","topArrowStyles: string","bottomArrowStyles: string","leftArrowStyles: string","rightArrowStyles: string"],"sources":["../../../../../src/components/primitives/Tooltip/Tooltip.styles.ts"],"sourcesContent":["// Copyright 2026 The ThunderID Authors\n// SPDX-License-Identifier: Apache-2.0\n\nimport {Theme} from '@thunderid/browser';\nimport {useMemo} from 'react';\nimport {css, keyframes} from '../../../styles/emotion';\n\nconst useStyles = (theme: Theme, colorScheme: string): Record<string, string> =>\n useMemo(() => {\n const fadeInAnimation = keyframes`\n from { opacity: 0; }\n to { opacity: 1; }\n `;\n\n const containerStyles: string = css`\n position: relative;\n display: inline-block;\n `;\n\n // white-space: nowrap;\n const boxStyles: string = css`\n position: absolute;\n background-color: #333;\n color: #fff;\n padding: 6px 12px;\n border-radius: 6px;\n font-size: 0.85rem;\n z-index: 1000;\n box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.15);\n animation: ${fadeInAnimation} 0.15s ease-in-out;\n\n min-width: 250px;\n white-space: normal;\n word-break: break-word;\n overflow-wrap: break-word;\n text-align: start;\n `;\n\n const topStyles: string = css`\n bottom: 100%;\n left: 50%;\n transform: translateX(-50%);\n margin-bottom: 8px;\n `;\n\n const bottomStyles: string = css`\n top: 100%;\n left: 50%;\n transform: translateX(-50%);\n margin-top: 8px;\n `;\n\n const leftStyles: string = css`\n right: 100%;\n top: 50%;\n transform: translateY(-50%);\n margin-right: 8px;\n `;\n\n const rightStyles: string = css`\n left: 100%;\n top: 50%;\n transform: translateY(-50%);\n margin-left: 8px;\n `;\n\n const arrowStyles: string = css`\n position: absolute;\n width: 0;\n height: 0;\n border-style: solid;\n `;\n\n const topArrowStyles: string = css`\n top: 100%;\n left: 50%;\n transform: translateX(-50%);\n border-width: 5px 5px 0 5px;\n border-color: #333 transparent transparent transparent;\n `;\n\n const bottomArrowStyles: string = css`\n bottom: 100%;\n left: 50%;\n transform: translateX(-50%);\n border-width: 0 5px 5px 5px;\n border-color: transparent transparent #333 transparent;\n `;\n\n const leftArrowStyles: string = css`\n left: 100%;\n top: 50%;\n transform: translateY(-50%);\n border-width: 5px 0 5px 5px;\n border-color: transparent transparent transparent #333;\n `;\n\n const rightArrowStyles: string = css`\n right: 100%;\n top: 50%;\n transform: translateY(-50%);\n border-width: 5px 5px 5px 0;\n border-color: transparent #333 transparent transparent;\n `;\n\n return {\n container: containerStyles,\n box: boxStyles,\n top: topStyles,\n bottom: bottomStyles,\n left: leftStyles,\n right: rightStyles,\n arrow: arrowStyles,\n 'top-arrow': topArrowStyles,\n 'bottom-arrow': bottomArrowStyles,\n 'left-arrow': leftArrowStyles,\n 'right-arrow': rightArrowStyles,\n };\n }, [theme, colorScheme]);\n\nexport default useStyles;\n"],"mappings":";;;;;;AAOA,MAAM,aAAa,OAAc,yCACjB;CACZ,MAAM,kBAAkB,yBAAS;;;;CAKjC,MAAMA,kBAA0B,mBAAG;;;;CAMnC,MAAMC,YAAoB,mBAAG;;;;;;;;;mBASd,gBAAgB;;;;;;;;CAS/B,MAAMC,YAAoB,mBAAG;;;;;;CAO7B,MAAMC,eAAuB,mBAAG;;;;;;CAOhC,MAAMC,aAAqB,mBAAG;;;;;;CAO9B,MAAMC,cAAsB,mBAAG;;;;;;CAO/B,MAAMC,cAAsB,mBAAG;;;;;;CAO/B,MAAMC,iBAAyB,mBAAG;;;;;;;CAQlC,MAAMC,oBAA4B,mBAAG;;;;;;;CAQrC,MAAMC,kBAA0B,mBAAG;;;;;;;CAQnC,MAAMC,mBAA2B,mBAAG;;;;;;;AAQpC,QAAO;EACL,WAAW;EACX,KAAK;EACL,KAAK;EACL,QAAQ;EACR,MAAM;EACN,OAAO;EACP,OAAO;EACP,aAAa;EACb,gBAAgB;EAChB,cAAc;EACd,eAAe;EAChB;GACA,CAAC,OAAO,YAAY,CAAC;AAE1B,6BAAe"}