@fluentui/react-dialog 9.4.0 → 9.4.1

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 (314) hide show
  1. package/.swcrc +30 -0
  2. package/CHANGELOG.json +88 -1
  3. package/CHANGELOG.md +23 -2
  4. package/lib/Dialog.js.map +1 -1
  5. package/lib/DialogActions.js.map +1 -1
  6. package/lib/DialogBody.js.map +1 -1
  7. package/lib/DialogContent.js.map +1 -1
  8. package/lib/DialogSurface.js.map +1 -1
  9. package/lib/DialogTitle.js.map +1 -1
  10. package/lib/DialogTrigger.js.map +1 -1
  11. package/lib/components/Dialog/Dialog.js.map +1 -1
  12. package/lib/components/Dialog/Dialog.types.js.map +1 -1
  13. package/lib/components/Dialog/index.js.map +1 -1
  14. package/lib/components/Dialog/renderDialog.js.map +1 -1
  15. package/lib/components/Dialog/useDialog.js.map +1 -1
  16. package/lib/components/Dialog/useDialogContextValues.js +3 -3
  17. package/lib/components/Dialog/useDialogContextValues.js.map +1 -1
  18. package/lib/components/DialogActions/DialogActions.js.map +1 -1
  19. package/lib/components/DialogActions/DialogActions.types.js.map +1 -1
  20. package/lib/components/DialogActions/index.js.map +1 -1
  21. package/lib/components/DialogActions/renderDialogActions.js +1 -3
  22. package/lib/components/DialogActions/renderDialogActions.js.map +1 -1
  23. package/lib/components/DialogActions/useDialogActions.js +1 -0
  24. package/lib/components/DialogActions/useDialogActions.js.map +1 -1
  25. package/lib/components/DialogActions/useDialogActionsStyles.js.map +1 -1
  26. package/lib/components/DialogBody/DialogBody.js.map +1 -1
  27. package/lib/components/DialogBody/DialogBody.types.js.map +1 -1
  28. package/lib/components/DialogBody/index.js.map +1 -1
  29. package/lib/components/DialogBody/renderDialogBody.js +1 -3
  30. package/lib/components/DialogBody/renderDialogBody.js.map +1 -1
  31. package/lib/components/DialogBody/useDialogBody.js +3 -2
  32. package/lib/components/DialogBody/useDialogBody.js.map +1 -1
  33. package/lib/components/DialogBody/useDialogBodyStyles.js.map +1 -1
  34. package/lib/components/DialogContent/DialogContent.js.map +1 -1
  35. package/lib/components/DialogContent/DialogContent.types.js.map +1 -1
  36. package/lib/components/DialogContent/index.js.map +1 -1
  37. package/lib/components/DialogContent/renderDialogContent.js +1 -3
  38. package/lib/components/DialogContent/renderDialogContent.js.map +1 -1
  39. package/lib/components/DialogContent/useDialogContent.js +3 -2
  40. package/lib/components/DialogContent/useDialogContent.js.map +1 -1
  41. package/lib/components/DialogContent/useDialogContentStyles.js.map +1 -1
  42. package/lib/components/DialogSurface/DialogSurface.js.map +1 -1
  43. package/lib/components/DialogSurface/DialogSurface.types.js.map +1 -1
  44. package/lib/components/DialogSurface/index.js.map +1 -1
  45. package/lib/components/DialogSurface/renderDialogSurface.js +2 -6
  46. package/lib/components/DialogSurface/renderDialogSurface.js.map +1 -1
  47. package/lib/components/DialogSurface/useDialogSurface.js +5 -4
  48. package/lib/components/DialogSurface/useDialogSurface.js.map +1 -1
  49. package/lib/components/DialogSurface/useDialogSurfaceContextValues.js.map +1 -1
  50. package/lib/components/DialogSurface/useDialogSurfaceStyles.js.map +1 -1
  51. package/lib/components/DialogTitle/DialogTitle.js.map +1 -1
  52. package/lib/components/DialogTitle/DialogTitle.types.js.map +1 -1
  53. package/lib/components/DialogTitle/index.js.map +1 -1
  54. package/lib/components/DialogTitle/renderDialogTitle.js +1 -5
  55. package/lib/components/DialogTitle/renderDialogTitle.js.map +1 -1
  56. package/lib/components/DialogTitle/useDialogTitle.js +2 -0
  57. package/lib/components/DialogTitle/useDialogTitle.js.map +1 -1
  58. package/lib/components/DialogTitle/useDialogTitleStyles.js.map +1 -1
  59. package/lib/components/DialogTrigger/DialogTrigger.js +1 -0
  60. package/lib/components/DialogTrigger/DialogTrigger.js.map +1 -1
  61. package/lib/components/DialogTrigger/DialogTrigger.types.js +1 -1
  62. package/lib/components/DialogTrigger/DialogTrigger.types.js.map +1 -1
  63. package/lib/components/DialogTrigger/index.js.map +1 -1
  64. package/lib/components/DialogTrigger/renderDialogTrigger.js +1 -2
  65. package/lib/components/DialogTrigger/renderDialogTrigger.js.map +1 -1
  66. package/lib/components/DialogTrigger/useDialogTrigger.js +3 -2
  67. package/lib/components/DialogTrigger/useDialogTrigger.js.map +1 -1
  68. package/lib/contexts/constants.js.map +1 -1
  69. package/lib/contexts/dialogContext.js +2 -2
  70. package/lib/contexts/dialogContext.js.map +1 -1
  71. package/lib/contexts/dialogSurfaceContext.js +2 -4
  72. package/lib/contexts/dialogSurfaceContext.js.map +1 -1
  73. package/lib/contexts/index.js.map +1 -1
  74. package/lib/index.js.map +1 -1
  75. package/lib/utils/index.js.map +1 -1
  76. package/lib/utils/isEscapeKeyDown.js +1 -0
  77. package/lib/utils/isEscapeKeyDown.js.map +1 -1
  78. package/lib/utils/useDisableBodyScroll.js +6 -5
  79. package/lib/utils/useDisableBodyScroll.js.map +1 -1
  80. package/lib/utils/useFocusFirstElement.js +4 -3
  81. package/lib/utils/useFocusFirstElement.js.map +1 -1
  82. package/lib-commonjs/Dialog.js +5 -4
  83. package/lib-commonjs/Dialog.js.map +1 -1
  84. package/lib-commonjs/DialogActions.js +5 -4
  85. package/lib-commonjs/DialogActions.js.map +1 -1
  86. package/lib-commonjs/DialogBody.js +5 -4
  87. package/lib-commonjs/DialogBody.js.map +1 -1
  88. package/lib-commonjs/DialogContent.js +5 -4
  89. package/lib-commonjs/DialogContent.js.map +1 -1
  90. package/lib-commonjs/DialogSurface.js +5 -4
  91. package/lib-commonjs/DialogSurface.js.map +1 -1
  92. package/lib-commonjs/DialogTitle.js +5 -4
  93. package/lib-commonjs/DialogTitle.js.map +1 -1
  94. package/lib-commonjs/DialogTrigger.js +5 -4
  95. package/lib-commonjs/DialogTrigger.js.map +1 -1
  96. package/lib-commonjs/components/Dialog/Dialog.js +16 -19
  97. package/lib-commonjs/components/Dialog/Dialog.js.map +1 -1
  98. package/lib-commonjs/components/Dialog/Dialog.types.js +3 -2
  99. package/lib-commonjs/components/Dialog/Dialog.types.js.map +1 -1
  100. package/lib-commonjs/components/Dialog/index.js +8 -7
  101. package/lib-commonjs/components/Dialog/index.js.map +1 -1
  102. package/lib-commonjs/components/Dialog/renderDialog.js +17 -20
  103. package/lib-commonjs/components/Dialog/renderDialog.js.map +1 -1
  104. package/lib-commonjs/components/Dialog/useDialog.js +78 -80
  105. package/lib-commonjs/components/Dialog/useDialog.js.map +1 -1
  106. package/lib-commonjs/components/Dialog/useDialogContextValues.js +25 -32
  107. package/lib-commonjs/components/Dialog/useDialogContextValues.js.map +1 -1
  108. package/lib-commonjs/components/DialogActions/DialogActions.js +19 -21
  109. package/lib-commonjs/components/DialogActions/DialogActions.js.map +1 -1
  110. package/lib-commonjs/components/DialogActions/DialogActions.types.js +3 -2
  111. package/lib-commonjs/components/DialogActions/DialogActions.types.js.map +1 -1
  112. package/lib-commonjs/components/DialogActions/index.js +9 -8
  113. package/lib-commonjs/components/DialogActions/index.js.map +1 -1
  114. package/lib-commonjs/components/DialogActions/renderDialogActions.js +14 -19
  115. package/lib-commonjs/components/DialogActions/renderDialogActions.js.map +1 -1
  116. package/lib-commonjs/components/DialogActions/useDialogActions.js +23 -31
  117. package/lib-commonjs/components/DialogActions/useDialogActions.js.map +1 -1
  118. package/lib-commonjs/components/DialogActions/useDialogActionsStyles.js +81 -52
  119. package/lib-commonjs/components/DialogActions/useDialogActionsStyles.js.map +1 -1
  120. package/lib-commonjs/components/DialogBody/DialogBody.js +19 -21
  121. package/lib-commonjs/components/DialogBody/DialogBody.js.map +1 -1
  122. package/lib-commonjs/components/DialogBody/DialogBody.types.js +3 -2
  123. package/lib-commonjs/components/DialogBody/DialogBody.types.js.map +1 -1
  124. package/lib-commonjs/components/DialogBody/index.js +9 -8
  125. package/lib-commonjs/components/DialogBody/index.js.map +1 -1
  126. package/lib-commonjs/components/DialogBody/renderDialogBody.js +14 -19
  127. package/lib-commonjs/components/DialogBody/renderDialogBody.js.map +1 -1
  128. package/lib-commonjs/components/DialogBody/useDialogBody.js +21 -26
  129. package/lib-commonjs/components/DialogBody/useDialogBody.js.map +1 -1
  130. package/lib-commonjs/components/DialogBody/useDialogBodyStyles.js +74 -44
  131. package/lib-commonjs/components/DialogBody/useDialogBodyStyles.js.map +1 -1
  132. package/lib-commonjs/components/DialogContent/DialogContent.js +19 -21
  133. package/lib-commonjs/components/DialogContent/DialogContent.js.map +1 -1
  134. package/lib-commonjs/components/DialogContent/DialogContent.types.js +3 -2
  135. package/lib-commonjs/components/DialogContent/DialogContent.types.js.map +1 -1
  136. package/lib-commonjs/components/DialogContent/index.js +9 -8
  137. package/lib-commonjs/components/DialogContent/index.js.map +1 -1
  138. package/lib-commonjs/components/DialogContent/renderDialogContent.js +13 -18
  139. package/lib-commonjs/components/DialogContent/renderDialogContent.js.map +1 -1
  140. package/lib-commonjs/components/DialogContent/useDialogContent.js +21 -26
  141. package/lib-commonjs/components/DialogContent/useDialogContent.js.map +1 -1
  142. package/lib-commonjs/components/DialogContent/useDialogContentStyles.js +51 -35
  143. package/lib-commonjs/components/DialogContent/useDialogContentStyles.js.map +1 -1
  144. package/lib-commonjs/components/DialogSurface/DialogSurface.js +21 -23
  145. package/lib-commonjs/components/DialogSurface/DialogSurface.js.map +1 -1
  146. package/lib-commonjs/components/DialogSurface/DialogSurface.types.js +3 -2
  147. package/lib-commonjs/components/DialogSurface/DialogSurface.types.js.map +1 -1
  148. package/lib-commonjs/components/DialogSurface/index.js +9 -8
  149. package/lib-commonjs/components/DialogSurface/index.js.map +1 -1
  150. package/lib-commonjs/components/DialogSurface/renderDialogSurface.js +17 -24
  151. package/lib-commonjs/components/DialogSurface/renderDialogSurface.js.map +1 -1
  152. package/lib-commonjs/components/DialogSurface/useDialogSurface.js +75 -85
  153. package/lib-commonjs/components/DialogSurface/useDialogSurface.js.map +1 -1
  154. package/lib-commonjs/components/DialogSurface/useDialogSurfaceContextValues.js +11 -9
  155. package/lib-commonjs/components/DialogSurface/useDialogSurfaceContextValues.js.map +1 -1
  156. package/lib-commonjs/components/DialogSurface/useDialogSurfaceStyles.js +309 -123
  157. package/lib-commonjs/components/DialogSurface/useDialogSurfaceStyles.js.map +1 -1
  158. package/lib-commonjs/components/DialogTitle/DialogTitle.js +19 -21
  159. package/lib-commonjs/components/DialogTitle/DialogTitle.js.map +1 -1
  160. package/lib-commonjs/components/DialogTitle/DialogTitle.types.js +3 -2
  161. package/lib-commonjs/components/DialogTitle/DialogTitle.types.js.map +1 -1
  162. package/lib-commonjs/components/DialogTitle/index.js +9 -8
  163. package/lib-commonjs/components/DialogTitle/index.js.map +1 -1
  164. package/lib-commonjs/components/DialogTitle/renderDialogTitle.js +13 -20
  165. package/lib-commonjs/components/DialogTitle/renderDialogTitle.js.map +1 -1
  166. package/lib-commonjs/components/DialogTitle/useDialogTitle.js +43 -51
  167. package/lib-commonjs/components/DialogTitle/useDialogTitle.js.map +1 -1
  168. package/lib-commonjs/components/DialogTitle/useDialogTitleStyles.js +225 -107
  169. package/lib-commonjs/components/DialogTitle/useDialogTitleStyles.js.map +1 -1
  170. package/lib-commonjs/components/DialogTrigger/DialogTrigger.js +15 -21
  171. package/lib-commonjs/components/DialogTrigger/DialogTrigger.js.map +1 -1
  172. package/lib-commonjs/components/DialogTrigger/DialogTrigger.types.js +5 -2
  173. package/lib-commonjs/components/DialogTrigger/DialogTrigger.types.js.map +1 -1
  174. package/lib-commonjs/components/DialogTrigger/index.js +8 -7
  175. package/lib-commonjs/components/DialogTrigger/index.js.map +1 -1
  176. package/lib-commonjs/components/DialogTrigger/renderDialogTrigger.js +10 -9
  177. package/lib-commonjs/components/DialogTrigger/renderDialogTrigger.js.map +1 -1
  178. package/lib-commonjs/components/DialogTrigger/useDialogTrigger.js +45 -53
  179. package/lib-commonjs/components/DialogTrigger/useDialogTrigger.js.map +1 -1
  180. package/lib-commonjs/contexts/constants.js +28 -12
  181. package/lib-commonjs/contexts/constants.js.map +1 -1
  182. package/lib-commonjs/contexts/dialogContext.js +28 -19
  183. package/lib-commonjs/contexts/dialogContext.js.map +1 -1
  184. package/lib-commonjs/contexts/dialogSurfaceContext.js +18 -11
  185. package/lib-commonjs/contexts/dialogSurfaceContext.js.map +1 -1
  186. package/lib-commonjs/contexts/index.js +7 -6
  187. package/lib-commonjs/contexts/index.js.map +1 -1
  188. package/lib-commonjs/index.js +50 -197
  189. package/lib-commonjs/index.js.map +1 -1
  190. package/lib-commonjs/utils/index.js +7 -6
  191. package/lib-commonjs/utils/index.js.map +1 -1
  192. package/lib-commonjs/utils/isEscapeKeyDown.js +11 -10
  193. package/lib-commonjs/utils/isEscapeKeyDown.js.map +1 -1
  194. package/lib-commonjs/utils/useDisableBodyScroll.js +45 -47
  195. package/lib-commonjs/utils/useDisableBodyScroll.js.map +1 -1
  196. package/lib-commonjs/utils/useFocusFirstElement.js +42 -37
  197. package/lib-commonjs/utils/useFocusFirstElement.js.map +1 -1
  198. package/package.json +14 -13
  199. package/lib-amd/Dialog.js +0 -6
  200. package/lib-amd/Dialog.js.map +0 -1
  201. package/lib-amd/DialogActions.js +0 -6
  202. package/lib-amd/DialogActions.js.map +0 -1
  203. package/lib-amd/DialogBody.js +0 -6
  204. package/lib-amd/DialogBody.js.map +0 -1
  205. package/lib-amd/DialogContent.js +0 -6
  206. package/lib-amd/DialogContent.js.map +0 -1
  207. package/lib-amd/DialogSurface.js +0 -6
  208. package/lib-amd/DialogSurface.js.map +0 -1
  209. package/lib-amd/DialogTitle.js +0 -6
  210. package/lib-amd/DialogTitle.js.map +0 -1
  211. package/lib-amd/DialogTrigger.js +0 -6
  212. package/lib-amd/DialogTrigger.js.map +0 -1
  213. package/lib-amd/components/Dialog/Dialog.js +0 -19
  214. package/lib-amd/components/Dialog/Dialog.js.map +0 -1
  215. package/lib-amd/components/Dialog/Dialog.types.js +0 -5
  216. package/lib-amd/components/Dialog/Dialog.types.js.map +0 -1
  217. package/lib-amd/components/Dialog/index.js +0 -9
  218. package/lib-amd/components/Dialog/index.js.map +0 -1
  219. package/lib-amd/components/Dialog/renderDialog.js +0 -17
  220. package/lib-amd/components/Dialog/renderDialog.js.map +0 -1
  221. package/lib-amd/components/Dialog/useDialog.js +0 -78
  222. package/lib-amd/components/Dialog/useDialog.js.map +0 -1
  223. package/lib-amd/components/Dialog/useDialogContextValues.js +0 -25
  224. package/lib-amd/components/Dialog/useDialogContextValues.js.map +0 -1
  225. package/lib-amd/components/DialogActions/DialogActions.js +0 -18
  226. package/lib-amd/components/DialogActions/DialogActions.js.map +0 -1
  227. package/lib-amd/components/DialogActions/DialogActions.types.js +0 -5
  228. package/lib-amd/components/DialogActions/DialogActions.types.js.map +0 -1
  229. package/lib-amd/components/DialogActions/index.js +0 -10
  230. package/lib-amd/components/DialogActions/index.js.map +0 -1
  231. package/lib-amd/components/DialogActions/renderDialogActions.js +0 -15
  232. package/lib-amd/components/DialogActions/renderDialogActions.js.map +0 -1
  233. package/lib-amd/components/DialogActions/useDialogActions.js +0 -27
  234. package/lib-amd/components/DialogActions/useDialogActions.js.map +0 -1
  235. package/lib-amd/components/DialogActions/useDialogActionsStyles.js +0 -33
  236. package/lib-amd/components/DialogActions/useDialogActionsStyles.js.map +0 -1
  237. package/lib-amd/components/DialogBody/DialogBody.js +0 -18
  238. package/lib-amd/components/DialogBody/DialogBody.js.map +0 -1
  239. package/lib-amd/components/DialogBody/DialogBody.types.js +0 -5
  240. package/lib-amd/components/DialogBody/DialogBody.types.js.map +0 -1
  241. package/lib-amd/components/DialogBody/index.js +0 -10
  242. package/lib-amd/components/DialogBody/index.js.map +0 -1
  243. package/lib-amd/components/DialogBody/renderDialogBody.js +0 -15
  244. package/lib-amd/components/DialogBody/renderDialogBody.js.map +0 -1
  245. package/lib-amd/components/DialogBody/useDialogBody.js +0 -25
  246. package/lib-amd/components/DialogBody/useDialogBody.js.map +0 -1
  247. package/lib-amd/components/DialogBody/useDialogBodyStyles.js +0 -31
  248. package/lib-amd/components/DialogBody/useDialogBodyStyles.js.map +0 -1
  249. package/lib-amd/components/DialogContent/DialogContent.js +0 -18
  250. package/lib-amd/components/DialogContent/DialogContent.js.map +0 -1
  251. package/lib-amd/components/DialogContent/DialogContent.types.js +0 -5
  252. package/lib-amd/components/DialogContent/DialogContent.types.js.map +0 -1
  253. package/lib-amd/components/DialogContent/index.js +0 -10
  254. package/lib-amd/components/DialogContent/index.js.map +0 -1
  255. package/lib-amd/components/DialogContent/renderDialogContent.js +0 -14
  256. package/lib-amd/components/DialogContent/renderDialogContent.js.map +0 -1
  257. package/lib-amd/components/DialogContent/useDialogContent.js +0 -25
  258. package/lib-amd/components/DialogContent/useDialogContent.js.map +0 -1
  259. package/lib-amd/components/DialogContent/useDialogContentStyles.js +0 -24
  260. package/lib-amd/components/DialogContent/useDialogContentStyles.js.map +0 -1
  261. package/lib-amd/components/DialogSurface/DialogSurface.js +0 -19
  262. package/lib-amd/components/DialogSurface/DialogSurface.js.map +0 -1
  263. package/lib-amd/components/DialogSurface/DialogSurface.types.js +0 -5
  264. package/lib-amd/components/DialogSurface/DialogSurface.types.js.map +0 -1
  265. package/lib-amd/components/DialogSurface/index.js +0 -10
  266. package/lib-amd/components/DialogSurface/index.js.map +0 -1
  267. package/lib-amd/components/DialogSurface/renderDialogSurface.js +0 -17
  268. package/lib-amd/components/DialogSurface/renderDialogSurface.js.map +0 -1
  269. package/lib-amd/components/DialogSurface/useDialogSurface.js +0 -70
  270. package/lib-amd/components/DialogSurface/useDialogSurface.js.map +0 -1
  271. package/lib-amd/components/DialogSurface/useDialogSurfaceContextValues.js +0 -11
  272. package/lib-amd/components/DialogSurface/useDialogSurfaceContextValues.js.map +0 -1
  273. package/lib-amd/components/DialogSurface/useDialogSurfaceStyles.js +0 -44
  274. package/lib-amd/components/DialogSurface/useDialogSurfaceStyles.js.map +0 -1
  275. package/lib-amd/components/DialogTitle/DialogTitle.js +0 -18
  276. package/lib-amd/components/DialogTitle/DialogTitle.js.map +0 -1
  277. package/lib-amd/components/DialogTitle/DialogTitle.types.js +0 -5
  278. package/lib-amd/components/DialogTitle/DialogTitle.types.js.map +0 -1
  279. package/lib-amd/components/DialogTitle/index.js +0 -10
  280. package/lib-amd/components/DialogTitle/index.js.map +0 -1
  281. package/lib-amd/components/DialogTitle/renderDialogTitle.js +0 -16
  282. package/lib-amd/components/DialogTitle/renderDialogTitle.js.map +0 -1
  283. package/lib-amd/components/DialogTitle/useDialogTitle.js +0 -36
  284. package/lib-amd/components/DialogTitle/useDialogTitle.js.map +0 -1
  285. package/lib-amd/components/DialogTitle/useDialogTitleStyles.js +0 -37
  286. package/lib-amd/components/DialogTitle/useDialogTitleStyles.js.map +0 -1
  287. package/lib-amd/components/DialogTrigger/DialogTrigger.js +0 -24
  288. package/lib-amd/components/DialogTrigger/DialogTrigger.js.map +0 -1
  289. package/lib-amd/components/DialogTrigger/DialogTrigger.types.js +0 -5
  290. package/lib-amd/components/DialogTrigger/DialogTrigger.types.js.map +0 -1
  291. package/lib-amd/components/DialogTrigger/index.js +0 -9
  292. package/lib-amd/components/DialogTrigger/index.js.map +0 -1
  293. package/lib-amd/components/DialogTrigger/renderDialogTrigger.js +0 -13
  294. package/lib-amd/components/DialogTrigger/renderDialogTrigger.js.map +0 -1
  295. package/lib-amd/components/DialogTrigger/useDialogTrigger.js +0 -37
  296. package/lib-amd/components/DialogTrigger/useDialogTrigger.js.map +0 -1
  297. package/lib-amd/contexts/constants.js +0 -15
  298. package/lib-amd/contexts/constants.js.map +0 -1
  299. package/lib-amd/contexts/dialogContext.js +0 -26
  300. package/lib-amd/contexts/dialogContext.js.map +0 -1
  301. package/lib-amd/contexts/dialogSurfaceContext.js +0 -11
  302. package/lib-amd/contexts/dialogSurfaceContext.js.map +0 -1
  303. package/lib-amd/contexts/index.js +0 -8
  304. package/lib-amd/contexts/index.js.map +0 -1
  305. package/lib-amd/index.js +0 -37
  306. package/lib-amd/index.js.map +0 -1
  307. package/lib-amd/utils/index.js +0 -8
  308. package/lib-amd/utils/index.js.map +0 -1
  309. package/lib-amd/utils/isEscapeKeyDown.js +0 -13
  310. package/lib-amd/utils/isEscapeKeyDown.js.map +0 -1
  311. package/lib-amd/utils/useDisableBodyScroll.js +0 -52
  312. package/lib-amd/utils/useDisableBodyScroll.js.map +0 -1
  313. package/lib-amd/utils/useFocusFirstElement.js +0 -38
  314. package/lib-amd/utils/useFocusFirstElement.js.map +0 -1
@@ -1,3 +1,4 @@
1
+ import * as React from 'react';
1
2
  import { getNativeElementProps } from '@fluentui/react-utilities';
2
3
  /**
3
4
  * Create the state required to render DialogBody.
@@ -9,12 +10,12 @@ import { getNativeElementProps } from '@fluentui/react-utilities';
9
10
  * @param ref - reference to root HTMLElement of DialogBody
10
11
  */
11
12
  export const useDialogContent_unstable = (props, ref) => {
12
- var _a;
13
+ var _props_as;
13
14
  return {
14
15
  components: {
15
16
  root: 'div'
16
17
  },
17
- root: getNativeElementProps((_a = props.as) !== null && _a !== void 0 ? _a : 'div', {
18
+ root: getNativeElementProps((_props_as = props.as) !== null && _props_as !== void 0 ? _props_as : 'div', {
18
19
  ref,
19
20
  ...props
20
21
  })
@@ -1 +1 @@
1
- {"version":3,"names":["getNativeElementProps","useDialogContent_unstable","props","ref","components","root","_a","as"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogContent/useDialogContent.ts"],"sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps } from '@fluentui/react-utilities';\nimport { DialogContentProps, DialogContentState } from './DialogContent.types';\n\n/**\n * Create the state required to render DialogBody.\n *\n * The returned state can be modified with hooks such as useDialogBodyStyles_unstable,\n * before being passed to renderDialogBody_unstable.\n *\n * @param props - props from this instance of DialogBody\n * @param ref - reference to root HTMLElement of DialogBody\n */\nexport const useDialogContent_unstable = (\n props: DialogContentProps,\n ref: React.Ref<HTMLElement>,\n): DialogContentState => {\n return {\n components: {\n root: 'div',\n },\n root: getNativeElementProps(props.as ?? 'div', {\n ref,\n ...props,\n }),\n };\n};\n"],"mappings":"AACA,SAASA,qBAAqB,QAAQ,2BAA2B;AAGjE;;;;;;;;;AASA,OAAO,MAAMC,yBAAyB,GAAGA,CACvCC,KAAyB,EACzBC,GAA2B,KACL;;EACtB,OAAO;IACLC,UAAU,EAAE;MACVC,IAAI,EAAE;KACP;IACDA,IAAI,EAAEL,qBAAqB,CAAC,CAAAM,EAAA,GAAAJ,KAAK,CAACK,EAAE,cAAAD,EAAA,cAAAA,EAAA,GAAI,KAAK,EAAE;MAC7CH,GAAG;MACH,GAAGD;KACJ;GACF;AACH,CAAC"}
1
+ {"version":3,"names":["React","getNativeElementProps","useDialogContent_unstable","props","ref","_props_as","components","root","as"],"sources":["../../../src/components/DialogContent/useDialogContent.ts"],"sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps } from '@fluentui/react-utilities';\nimport { DialogContentProps, DialogContentState } from './DialogContent.types';\n\n/**\n * Create the state required to render DialogBody.\n *\n * The returned state can be modified with hooks such as useDialogBodyStyles_unstable,\n * before being passed to renderDialogBody_unstable.\n *\n * @param props - props from this instance of DialogBody\n * @param ref - reference to root HTMLElement of DialogBody\n */\nexport const useDialogContent_unstable = (\n props: DialogContentProps,\n ref: React.Ref<HTMLElement>,\n): DialogContentState => {\n return {\n components: {\n root: 'div',\n },\n root: getNativeElementProps(props.as ?? 'div', {\n ref,\n ...props,\n }),\n };\n};\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SAASC,qBAAqB,QAAQ;AAGtC;;;;;;;;;AASA,OAAO,MAAMC,yBAAA,GAA4BA,CACvCC,KAAA,EACAC,GAAA,KACuB;MAKOC,SAAA;EAJ9B,OAAO;IACLC,UAAA,EAAY;MACVC,IAAA,EAAM;IACR;IACAA,IAAA,EAAMN,qBAAA,CAAsB,CAAAI,SAAA,GAAAF,KAAA,CAAMK,EAAE,cAARH,SAAA,cAAAA,SAAA,GAAY,KAAK,EAAE;MAC7CD,GAAA;MACA,GAAGD;IACL;EACF;AACF"}
@@ -1 +1 @@
1
- {"version":3,"names":["__styles","mergeClasses","shorthands","CONTENT_GRID_AREA","typographyStyles","dialogContentClassNames","root","useStyles","a9b677","Bqenvij","Bmxbyg5","sshi5w","B7ck84d","Ijaq50","Br312pm","nk6f5a","Bw0ie65","Bahqtrf","Be2twd7","Bhrd7zp","Bg96gwp","d","useDialogContentStyles_unstable","state","styles","className"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogContent/useDialogContentStyles.ts"],"sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport type { DialogContentSlots, DialogContentState } from './DialogContent.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\nimport { CONTENT_GRID_AREA } from '../../contexts/constants';\nimport { typographyStyles } from '@fluentui/react-theme';\n\nexport const dialogContentClassNames: SlotClassNames<DialogContentSlots> = {\n root: 'fui-DialogContent',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n width: '100%',\n height: '100%',\n overflowY: 'auto',\n minHeight: '32px',\n boxSizing: 'border-box',\n ...shorthands.gridArea(CONTENT_GRID_AREA),\n ...typographyStyles.body1,\n },\n});\n\n/**\n * Apply styling to the DialogContent slots based on the state\n */\nexport const useDialogContentStyles_unstable = (state: DialogContentState): DialogContentState => {\n const styles = useStyles();\n state.root.className = mergeClasses(dialogContentClassNames.root, styles.root, state.root.className);\n return state;\n};\n"],"mappings":"AAAA,SAAAA,QAAA,EAAqBC,YAAY,EAAEC,UAAU,QAAQ,gBAAgB;AAGrE,SAASC,iBAAiB,QAAQ,0BAA0B;AAC5D,SAASC,gBAAgB,QAAQ,uBAAuB;AAExD,OAAO,MAAMC,uBAAuB,GAAuC;EACzEC,IAAI,EAAE;CACP;AAED;;;AAGA,MAAMC,SAAS,gBAAGP,QAAA;EAAAM,IAAA;IAAAE,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;EAAA;AAAA;EAAAC,CAAA;AAAA,EAUhB;AAEF;;;AAGA,OAAO,MAAMC,+BAA+B,GAAIC,KAAyB,IAAwB;EAC/F,MAAMC,MAAM,GAAGjB,SAAS,EAAE;EAC1BgB,KAAK,CAACjB,IAAI,CAACmB,SAAS,GAAGxB,YAAY,CAACI,uBAAuB,CAACC,IAAI,EAAEkB,MAAM,CAAClB,IAAI,EAAEiB,KAAK,CAACjB,IAAI,CAACmB,SAAS,CAAC;EACpG,OAAOF,KAAK;AACd,CAAC"}
1
+ {"version":3,"names":["__styles","mergeClasses","shorthands","CONTENT_GRID_AREA","typographyStyles","dialogContentClassNames","root","useStyles","a9b677","Bqenvij","Bmxbyg5","sshi5w","B7ck84d","Ijaq50","Br312pm","nk6f5a","Bw0ie65","Bahqtrf","Be2twd7","Bhrd7zp","Bg96gwp","d","useDialogContentStyles_unstable","state","styles","className"],"sources":["../../../src/components/DialogContent/useDialogContentStyles.ts"],"sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport type { DialogContentSlots, DialogContentState } from './DialogContent.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\nimport { CONTENT_GRID_AREA } from '../../contexts/constants';\nimport { typographyStyles } from '@fluentui/react-theme';\n\nexport const dialogContentClassNames: SlotClassNames<DialogContentSlots> = {\n root: 'fui-DialogContent',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n width: '100%',\n height: '100%',\n overflowY: 'auto',\n minHeight: '32px',\n boxSizing: 'border-box',\n ...shorthands.gridArea(CONTENT_GRID_AREA),\n ...typographyStyles.body1,\n },\n});\n\n/**\n * Apply styling to the DialogContent slots based on the state\n */\nexport const useDialogContentStyles_unstable = (state: DialogContentState): DialogContentState => {\n const styles = useStyles();\n state.root.className = mergeClasses(dialogContentClassNames.root, styles.root, state.root.className);\n return state;\n};\n"],"mappings":"AAAA,SAAAA,QAAA,EAAqBC,YAAY,EAAEC,UAAU,QAAQ;AAGrD,SAASC,iBAAiB,QAAQ;AAClC,SAASC,gBAAgB,QAAQ;AAEjC,OAAO,MAAMC,uBAAA,GAA8D;EACzEC,IAAA,EAAM;AACR;AAEA;;;AAGA,MAAMC,SAAA,gBAAYP,QAAA;EAAAM,IAAA;IAAAE,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;EAAA;AAAA;EAAAC,CAAA;AAAA,EAUlB;AAEA;;;AAGA,OAAO,MAAMC,+BAAA,GAAmCC,KAAA,IAAkD;EAChG,MAAMC,MAAA,GAASjB,SAAA;EACfgB,KAAA,CAAMjB,IAAI,CAACmB,SAAS,GAAGxB,YAAA,CAAaI,uBAAA,CAAwBC,IAAI,EAAEkB,MAAA,CAAOlB,IAAI,EAAEiB,KAAA,CAAMjB,IAAI,CAACmB,SAAS;EACnG,OAAOF,KAAA;AACT"}
@@ -1 +1 @@
1
- {"version":3,"names":["React","useDialogSurface_unstable","renderDialogSurface_unstable","useDialogSurfaceStyles_unstable","useDialogSurfaceContextValues_unstable","useCustomStyleHooks_unstable","DialogSurface","forwardRef","props","ref","state","contextValues","useCustomStyles","displayName"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogSurface/DialogSurface.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useDialogSurface_unstable } from './useDialogSurface';\nimport { renderDialogSurface_unstable } from './renderDialogSurface';\nimport { useDialogSurfaceStyles_unstable } from './useDialogSurfaceStyles';\nimport type { DialogSurfaceProps } from './DialogSurface.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useDialogSurfaceContextValues_unstable } from './useDialogSurfaceContextValues';\nimport { useCustomStyleHooks_unstable } from '@fluentui/react-shared-contexts';\n\n/**\n * DialogSurface component represents the visual part of a `Dialog` as a whole,\n * it contains everything that should be visible.\n */\nexport const DialogSurface: ForwardRefComponent<DialogSurfaceProps> = React.forwardRef((props, ref) => {\n const state = useDialogSurface_unstable(props, ref);\n const contextValues = useDialogSurfaceContextValues_unstable(state);\n\n useDialogSurfaceStyles_unstable(state);\n\n const { useDialogSurfaceStyles_unstable: useCustomStyles } = useCustomStyleHooks_unstable();\n useCustomStyles(state);\n\n return renderDialogSurface_unstable(state, contextValues);\n});\n\nDialogSurface.displayName = 'DialogSurface';\n"],"mappings":"AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,SAASC,yBAAyB,QAAQ,oBAAoB;AAC9D,SAASC,4BAA4B,QAAQ,uBAAuB;AACpE,SAASC,+BAA+B,QAAQ,0BAA0B;AAG1E,SAASC,sCAAsC,QAAQ,iCAAiC;AACxF,SAASC,4BAA4B,QAAQ,iCAAiC;AAE9E;;;;AAIA,OAAO,MAAMC,aAAa,gBAA4CN,KAAK,CAACO,UAAU,CAAC,CAACC,KAAK,EAAEC,GAAG,KAAI;EACpG,MAAMC,KAAK,GAAGT,yBAAyB,CAACO,KAAK,EAAEC,GAAG,CAAC;EACnD,MAAME,aAAa,GAAGP,sCAAsC,CAACM,KAAK,CAAC;EAEnEP,+BAA+B,CAACO,KAAK,CAAC;EAEtC,MAAM;IAAEP,+BAA+B,EAAES;EAAe,CAAE,GAAGP,4BAA4B,EAAE;EAC3FO,eAAe,CAACF,KAAK,CAAC;EAEtB,OAAOR,4BAA4B,CAACQ,KAAK,EAAEC,aAAa,CAAC;AAC3D,CAAC,CAAC;AAEFL,aAAa,CAACO,WAAW,GAAG,eAAe"}
1
+ {"version":3,"names":["React","useDialogSurface_unstable","renderDialogSurface_unstable","useDialogSurfaceStyles_unstable","useDialogSurfaceContextValues_unstable","useCustomStyleHooks_unstable","DialogSurface","forwardRef","props","ref","state","contextValues","useCustomStyles","displayName"],"sources":["../../../src/components/DialogSurface/DialogSurface.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useDialogSurface_unstable } from './useDialogSurface';\nimport { renderDialogSurface_unstable } from './renderDialogSurface';\nimport { useDialogSurfaceStyles_unstable } from './useDialogSurfaceStyles';\nimport type { DialogSurfaceProps } from './DialogSurface.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useDialogSurfaceContextValues_unstable } from './useDialogSurfaceContextValues';\nimport { useCustomStyleHooks_unstable } from '@fluentui/react-shared-contexts';\n\n/**\n * DialogSurface component represents the visual part of a `Dialog` as a whole,\n * it contains everything that should be visible.\n */\nexport const DialogSurface: ForwardRefComponent<DialogSurfaceProps> = React.forwardRef((props, ref) => {\n const state = useDialogSurface_unstable(props, ref);\n const contextValues = useDialogSurfaceContextValues_unstable(state);\n\n useDialogSurfaceStyles_unstable(state);\n\n const { useDialogSurfaceStyles_unstable: useCustomStyles } = useCustomStyleHooks_unstable();\n useCustomStyles(state);\n\n return renderDialogSurface_unstable(state, contextValues);\n});\n\nDialogSurface.displayName = 'DialogSurface';\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SAASC,yBAAyB,QAAQ;AAC1C,SAASC,4BAA4B,QAAQ;AAC7C,SAASC,+BAA+B,QAAQ;AAGhD,SAASC,sCAAsC,QAAQ;AACvD,SAASC,4BAA4B,QAAQ;AAE7C;;;;AAIA,OAAO,MAAMC,aAAA,gBAAyDN,KAAA,CAAMO,UAAU,CAAC,CAACC,KAAA,EAAOC,GAAA,KAAQ;EACrG,MAAMC,KAAA,GAAQT,yBAAA,CAA0BO,KAAA,EAAOC,GAAA;EAC/C,MAAME,aAAA,GAAgBP,sCAAA,CAAuCM,KAAA;EAE7DP,+BAAA,CAAgCO,KAAA;EAEhC,MAAM;IAAEP,+BAAA,EAAiCS;EAAe,CAAE,GAAGP,4BAAA;EAC7DO,eAAA,CAAgBF,KAAA;EAEhB,OAAOR,4BAAA,CAA6BQ,KAAA,EAAOC,aAAA;AAC7C;AAEAL,aAAA,CAAcO,WAAW,GAAG"}
@@ -1 +1 @@
1
- {"version":3,"file":"DialogSurface.types.js","sourceRoot":"../src/","sources":["packages/react-components/react-dialog/src/components/DialogSurface/DialogSurface.types.ts"],"names":[],"mappings":"","sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\nimport { DialogSurfaceContextValue } from '../../contexts';\n\nexport type DialogSurfaceSlots = {\n /**\n * Dimmed background of dialog.\n * The default backdrop is rendered as a `<div>` with styling.\n * This slot expects a `<div>` element which will replace the default backdrop.\n * The backdrop should have `aria-hidden=\"true\"`.\n *\n * By default if `DialogSurface` is `<dialog>` element the backdrop is ignored,\n * since native `<dialog>` element supports [::backdrop](https://developer.mozilla.org/en-US/docs/Web/CSS/::backdrop)\n */\n backdrop?: Slot<'div'>;\n root: Slot<'div'>;\n};\n\n/**\n * Union between all possible semantic element that represent a DialogSurface\n */\nexport type DialogSurfaceElement = HTMLDialogElement | HTMLDivElement;\n\n/** @internal */\nexport type DialogSurfaceElementIntersection = HTMLDialogElement & HTMLDivElement;\n\n/**\n * DialogSurface Props\n *\n * Omits basic types from native `dialog` (`open`, `onCancel` and `onClose`)\n * to ensure `onOpenChange`, `open` and `defaultOpen` from `Dialog` is used instead\n */\nexport type DialogSurfaceProps = Omit<ComponentProps<DialogSurfaceSlots>, 'open' | 'onCancel' | 'onClose'>;\n\nexport type DialogSurfaceContextValues = {\n dialogSurface: DialogSurfaceContextValue;\n};\n\n/**\n * State used in rendering DialogSurface\n */\nexport type DialogSurfaceState = ComponentState<DialogSurfaceSlots>;\n"]}
1
+ {"version":3,"names":[],"sources":["../../../src/components/DialogSurface/DialogSurface.types.ts"],"sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\nimport { DialogSurfaceContextValue } from '../../contexts';\n\nexport type DialogSurfaceSlots = {\n /**\n * Dimmed background of dialog.\n * The default backdrop is rendered as a `<div>` with styling.\n * This slot expects a `<div>` element which will replace the default backdrop.\n * The backdrop should have `aria-hidden=\"true\"`.\n *\n * By default if `DialogSurface` is `<dialog>` element the backdrop is ignored,\n * since native `<dialog>` element supports [::backdrop](https://developer.mozilla.org/en-US/docs/Web/CSS/::backdrop)\n */\n backdrop?: Slot<'div'>;\n root: Slot<'div'>;\n};\n\n/**\n * Union between all possible semantic element that represent a DialogSurface\n */\nexport type DialogSurfaceElement = HTMLDialogElement | HTMLDivElement;\n\n/** @internal */\nexport type DialogSurfaceElementIntersection = HTMLDialogElement & HTMLDivElement;\n\n/**\n * DialogSurface Props\n *\n * Omits basic types from native `dialog` (`open`, `onCancel` and `onClose`)\n * to ensure `onOpenChange`, `open` and `defaultOpen` from `Dialog` is used instead\n */\nexport type DialogSurfaceProps = Omit<ComponentProps<DialogSurfaceSlots>, 'open' | 'onCancel' | 'onClose'>;\n\nexport type DialogSurfaceContextValues = {\n dialogSurface: DialogSurfaceContextValue;\n};\n\n/**\n * State used in rendering DialogSurface\n */\nexport type DialogSurfaceState = ComponentState<DialogSurfaceSlots>;\n"],"mappings":"AAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["packages/react-components/react-dialog/src/components/DialogSurface/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,uBAAuB,CAAC;AACtC,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC;AACnC,cAAc,0BAA0B,CAAC","sourcesContent":["export * from './DialogSurface';\nexport * from './DialogSurface.types';\nexport * from './renderDialogSurface';\nexport * from './useDialogSurface';\nexport * from './useDialogSurfaceStyles';\n"]}
1
+ {"version":3,"names":[],"sources":["../../../src/components/DialogSurface/index.ts"],"sourcesContent":["export * from './DialogSurface';\nexport * from './DialogSurface.types';\nexport * from './renderDialogSurface';\nexport * from './useDialogSurface';\nexport * from './useDialogSurfaceStyles';\n"],"mappings":"AAAA,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc"}
@@ -10,12 +10,8 @@ export const renderDialogSurface_unstable = (state, contextValues) => {
10
10
  slots,
11
11
  slotProps
12
12
  } = getSlots(state);
13
- return /*#__PURE__*/React.createElement(Portal, null, slots.backdrop && /*#__PURE__*/React.createElement(slots.backdrop, {
14
- ...slotProps.backdrop
15
- }), /*#__PURE__*/React.createElement(DialogSurfaceProvider, {
13
+ return /*#__PURE__*/React.createElement(Portal, null, slots.backdrop && /*#__PURE__*/React.createElement(slots.backdrop, slotProps.backdrop), /*#__PURE__*/React.createElement(DialogSurfaceProvider, {
16
14
  value: contextValues.dialogSurface
17
- }, /*#__PURE__*/React.createElement(slots.root, {
18
- ...slotProps.root
19
- })));
15
+ }, /*#__PURE__*/React.createElement(slots.root, slotProps.root)));
20
16
  };
21
17
  //# sourceMappingURL=renderDialogSurface.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["React","getSlots","DialogSurfaceProvider","Portal","renderDialogSurface_unstable","state","contextValues","slots","slotProps","createElement","backdrop","value","dialogSurface","root"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogSurface/renderDialogSurface.tsx"],"sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { DialogSurfaceState, DialogSurfaceSlots, DialogSurfaceContextValues } from './DialogSurface.types';\nimport { DialogSurfaceProvider } from '../../contexts';\nimport { Portal } from '@fluentui/react-portal';\n\n/**\n * Render the final JSX of DialogSurface\n */\nexport const renderDialogSurface_unstable = (state: DialogSurfaceState, contextValues: DialogSurfaceContextValues) => {\n const { slots, slotProps } = getSlots<DialogSurfaceSlots>(state);\n\n return (\n <Portal>\n {slots.backdrop && <slots.backdrop {...slotProps.backdrop} />}\n <DialogSurfaceProvider value={contextValues.dialogSurface}>\n <slots.root {...slotProps.root} />\n </DialogSurfaceProvider>\n </Portal>\n );\n};\n"],"mappings":"AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,SAASC,QAAQ,QAAQ,2BAA2B;AAEpD,SAASC,qBAAqB,QAAQ,gBAAgB;AACtD,SAASC,MAAM,QAAQ,wBAAwB;AAE/C;;;AAGA,OAAO,MAAMC,4BAA4B,GAAGA,CAACC,KAAyB,EAAEC,aAAyC,KAAI;EACnH,MAAM;IAAEC,KAAK;IAAEC;EAAS,CAAE,GAAGP,QAAQ,CAAqBI,KAAK,CAAC;EAEhE,oBACEL,KAAA,CAAAS,aAAA,CAACN,MAAM,QACJI,KAAK,CAACG,QAAQ,iBAAIV,KAAA,CAAAS,aAAA,CAACF,KAAK,CAACG,QAAQ;IAAA,GAAKF,SAAS,CAACE;EAAQ,EAAI,eAC7DV,KAAA,CAAAS,aAAA,CAACP,qBAAqB;IAACS,KAAK,EAAEL,aAAa,CAACM;EAAa,gBACvDZ,KAAA,CAAAS,aAAA,CAACF,KAAK,CAACM,IAAI;IAAA,GAAKL,SAAS,CAACK;EAAI,EAAI,CACZ,CACjB;AAEb,CAAC"}
1
+ {"version":3,"names":["React","getSlots","DialogSurfaceProvider","Portal","renderDialogSurface_unstable","state","contextValues","slots","slotProps","createElement","backdrop","value","dialogSurface","root"],"sources":["../../../src/components/DialogSurface/renderDialogSurface.tsx"],"sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { DialogSurfaceState, DialogSurfaceSlots, DialogSurfaceContextValues } from './DialogSurface.types';\nimport { DialogSurfaceProvider } from '../../contexts';\nimport { Portal } from '@fluentui/react-portal';\n\n/**\n * Render the final JSX of DialogSurface\n */\nexport const renderDialogSurface_unstable = (state: DialogSurfaceState, contextValues: DialogSurfaceContextValues) => {\n const { slots, slotProps } = getSlots<DialogSurfaceSlots>(state);\n\n return (\n <Portal>\n {slots.backdrop && <slots.backdrop {...slotProps.backdrop} />}\n <DialogSurfaceProvider value={contextValues.dialogSurface}>\n <slots.root {...slotProps.root} />\n </DialogSurfaceProvider>\n </Portal>\n );\n};\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SAASC,QAAQ,QAAQ;AAEzB,SAASC,qBAAqB,QAAQ;AACtC,SAASC,MAAM,QAAQ;AAEvB;;;AAGA,OAAO,MAAMC,4BAAA,GAA+BA,CAACC,KAAA,EAA2BC,aAAA,KAA8C;EACpH,MAAM;IAAEC,KAAA;IAAOC;EAAS,CAAE,GAAGP,QAAA,CAA6BI,KAAA;EAE1D,oBACEL,KAAA,CAAAS,aAAA,CAACN,MAAA,QACEI,KAAA,CAAMG,QAAQ,iBAAIV,KAAA,CAAAS,aAAA,CAACF,KAAA,CAAMG,QAAQ,EAAKF,SAAA,CAAUE,QAAQ,gBACzDV,KAAA,CAAAS,aAAA,CAACP,qBAAA;IAAsBS,KAAA,EAAOL,aAAA,CAAcM;kBAC1CZ,KAAA,CAAAS,aAAA,CAACF,KAAA,CAAMM,IAAI,EAAKL,SAAA,CAAUK,IAAI;AAItC"}
@@ -1,3 +1,4 @@
1
+ import * as React from 'react';
1
2
  import { getNativeElementProps, resolveShorthand, useEventCallback, useMergedRefs, isResolvedShorthand } from '@fluentui/react-utilities';
2
3
  import { useDialogContext_unstable } from '../../contexts';
3
4
  import { isEscapeKeyDismiss } from '../../utils';
@@ -23,9 +24,9 @@ export const useDialogSurface_unstable = (props, ref) => {
23
24
  const requestOpenChange = useDialogContext_unstable(ctx => ctx.requestOpenChange);
24
25
  const dialogTitleID = useDialogContext_unstable(ctx => ctx.dialogTitleId);
25
26
  const handledBackdropClick = useEventCallback(event => {
26
- var _a, _b;
27
27
  if (isResolvedShorthand(props.backdrop)) {
28
- (_b = (_a = props.backdrop).onClick) === null || _b === void 0 ? void 0 : _b.call(_a, event);
28
+ var _props_backdrop, _props_backdrop_onClick;
29
+ (_props_backdrop_onClick = (_props_backdrop = props.backdrop).onClick) === null || _props_backdrop_onClick === void 0 ? void 0 : _props_backdrop_onClick.call(_props_backdrop, event);
29
30
  }
30
31
  if (modalType === 'modal' && !event.isDefaultPrevented()) {
31
32
  requestOpenChange({
@@ -36,8 +37,8 @@ export const useDialogSurface_unstable = (props, ref) => {
36
37
  }
37
38
  });
38
39
  const handleKeyDown = useEventCallback(event => {
39
- var _a;
40
- (_a = props.onKeyDown) === null || _a === void 0 ? void 0 : _a.call(props, event);
40
+ var _props_onKeyDown;
41
+ (_props_onKeyDown = props.onKeyDown) === null || _props_onKeyDown === void 0 ? void 0 : _props_onKeyDown.call(props, event);
41
42
  if (isEscapeKeyDismiss(event, modalType)) {
42
43
  requestOpenChange({
43
44
  event,
@@ -1 +1 @@
1
- {"version":3,"names":["getNativeElementProps","resolveShorthand","useEventCallback","useMergedRefs","isResolvedShorthand","useDialogContext_unstable","isEscapeKeyDismiss","useModalAttributes","useDialogSurface_unstable","props","ref","backdrop","as","modalType","ctx","inertTrapFocus","dialogRef","open","requestOpenChange","dialogTitleID","dialogTitleId","handledBackdropClick","event","_b","_a","onClick","call","isDefaultPrevented","type","handleKeyDown","onKeyDown","stopPropagation","modalAttributes","trapFocus","legacyTrapFocus","components","root","required","defaultProps","tabIndex","role","undefined"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogSurface/useDialogSurface.ts"],"sourcesContent":["import * as React from 'react';\nimport {\n getNativeElementProps,\n resolveShorthand,\n useEventCallback,\n useMergedRefs,\n isResolvedShorthand,\n} from '@fluentui/react-utilities';\nimport type {\n DialogSurfaceElement,\n DialogSurfaceElementIntersection,\n DialogSurfaceProps,\n DialogSurfaceState,\n} from './DialogSurface.types';\nimport { useDialogContext_unstable } from '../../contexts';\nimport { isEscapeKeyDismiss } from '../../utils';\nimport { useModalAttributes } from '@fluentui/react-tabster';\n\n/**\n * Create the state required to render DialogSurface.\n *\n * The returned state can be modified with hooks such as useDialogSurfaceStyles_unstable,\n * before being passed to renderDialogSurface_unstable.\n *\n * @param props - props from this instance of DialogSurface\n * @param ref - reference to root HTMLElement of DialogSurface\n */\nexport const useDialogSurface_unstable = (\n props: DialogSurfaceProps,\n ref: React.Ref<DialogSurfaceElement>,\n): DialogSurfaceState => {\n const { backdrop, as } = props;\n const modalType = useDialogContext_unstable(ctx => ctx.modalType);\n const inertTrapFocus = useDialogContext_unstable(ctx => ctx.inertTrapFocus);\n const dialogRef = useDialogContext_unstable(ctx => ctx.dialogRef);\n const open = useDialogContext_unstable(ctx => ctx.open);\n const requestOpenChange = useDialogContext_unstable(ctx => ctx.requestOpenChange);\n const dialogTitleID = useDialogContext_unstable(ctx => ctx.dialogTitleId);\n\n const handledBackdropClick = useEventCallback((event: React.MouseEvent<HTMLDivElement>) => {\n if (isResolvedShorthand(props.backdrop)) {\n props.backdrop.onClick?.(event);\n }\n if (modalType === 'modal' && !event.isDefaultPrevented()) {\n requestOpenChange({\n event,\n open: false,\n type: 'backdropClick',\n });\n }\n });\n\n const handleKeyDown = useEventCallback((event: React.KeyboardEvent<DialogSurfaceElementIntersection>) => {\n props.onKeyDown?.(event);\n\n if (isEscapeKeyDismiss(event, modalType)) {\n requestOpenChange({\n event,\n open: false,\n type: 'escapeKeyDown',\n });\n // stop propagation to avoid conflicting with other elements that listen for `Escape`\n // e,g: nested Dialog, Popover, Menu and Tooltip\n event.stopPropagation();\n }\n });\n\n const { modalAttributes } = useModalAttributes({\n trapFocus: modalType !== 'non-modal',\n legacyTrapFocus: !inertTrapFocus,\n });\n\n return {\n components: {\n backdrop: 'div',\n root: 'div',\n },\n backdrop: resolveShorthand(backdrop, {\n required: open && modalType !== 'non-modal',\n defaultProps: {\n 'aria-hidden': 'true',\n onClick: handledBackdropClick,\n },\n }),\n root: getNativeElementProps(as ?? 'div', {\n tabIndex: -1, // https://github.com/microsoft/fluentui/issues/25150\n 'aria-modal': modalType !== 'non-modal',\n role: modalType === 'alert' ? 'alertdialog' : 'dialog',\n 'aria-labelledby': props['aria-label'] ? undefined : dialogTitleID,\n ...props,\n ...modalAttributes,\n onKeyDown: handleKeyDown,\n ref: useMergedRefs(ref, dialogRef),\n }),\n };\n};\n"],"mappings":"AACA,SACEA,qBAAqB,EACrBC,gBAAgB,EAChBC,gBAAgB,EAChBC,aAAa,EACbC,mBAAmB,QACd,2BAA2B;AAOlC,SAASC,yBAAyB,QAAQ,gBAAgB;AAC1D,SAASC,kBAAkB,QAAQ,aAAa;AAChD,SAASC,kBAAkB,QAAQ,yBAAyB;AAE5D;;;;;;;;;AASA,OAAO,MAAMC,yBAAyB,GAAGA,CACvCC,KAAyB,EACzBC,GAAoC,KACd;EACtB,MAAM;IAAEC,QAAQ;IAAEC;EAAE,CAAE,GAAGH,KAAK;EAC9B,MAAMI,SAAS,GAAGR,yBAAyB,CAACS,GAAG,IAAIA,GAAG,CAACD,SAAS,CAAC;EACjE,MAAME,cAAc,GAAGV,yBAAyB,CAACS,GAAG,IAAIA,GAAG,CAACC,cAAc,CAAC;EAC3E,MAAMC,SAAS,GAAGX,yBAAyB,CAACS,GAAG,IAAIA,GAAG,CAACE,SAAS,CAAC;EACjE,MAAMC,IAAI,GAAGZ,yBAAyB,CAACS,GAAG,IAAIA,GAAG,CAACG,IAAI,CAAC;EACvD,MAAMC,iBAAiB,GAAGb,yBAAyB,CAACS,GAAG,IAAIA,GAAG,CAACI,iBAAiB,CAAC;EACjF,MAAMC,aAAa,GAAGd,yBAAyB,CAACS,GAAG,IAAIA,GAAG,CAACM,aAAa,CAAC;EAEzE,MAAMC,oBAAoB,GAAGnB,gBAAgB,CAAEoB,KAAuC,IAAI;;IACxF,IAAIlB,mBAAmB,CAACK,KAAK,CAACE,QAAQ,CAAC,EAAE;MACvC,CAAAY,EAAA,IAAAC,EAAA,GAAAf,KAAK,CAACE,QAAQ,EAACc,OAAO,cAAAF,EAAA,uBAAAA,EAAA,CAAAG,IAAA,CAAAF,EAAA,EAAGF,KAAK,CAAC;;IAEjC,IAAIT,SAAS,KAAK,OAAO,IAAI,CAACS,KAAK,CAACK,kBAAkB,EAAE,EAAE;MACxDT,iBAAiB,CAAC;QAChBI,KAAK;QACLL,IAAI,EAAE,KAAK;QACXW,IAAI,EAAE;OACP,CAAC;;EAEN,CAAC,CAAC;EAEF,MAAMC,aAAa,GAAG3B,gBAAgB,CAAEoB,KAA4D,IAAI;;IACtG,CAAAE,EAAA,GAAAf,KAAK,CAACqB,SAAS,cAAAN,EAAA,uBAAAA,EAAA,CAAAE,IAAA,CAAfjB,KAAK,EAAaa,KAAK,CAAC;IAExB,IAAIhB,kBAAkB,CAACgB,KAAK,EAAET,SAAS,CAAC,EAAE;MACxCK,iBAAiB,CAAC;QAChBI,KAAK;QACLL,IAAI,EAAE,KAAK;QACXW,IAAI,EAAE;OACP,CAAC;MACF;MACA;MACAN,KAAK,CAACS,eAAe,EAAE;;EAE3B,CAAC,CAAC;EAEF,MAAM;IAAEC;EAAe,CAAE,GAAGzB,kBAAkB,CAAC;IAC7C0B,SAAS,EAAEpB,SAAS,KAAK,WAAW;IACpCqB,eAAe,EAAE,CAACnB;GACnB,CAAC;EAEF,OAAO;IACLoB,UAAU,EAAE;MACVxB,QAAQ,EAAE,KAAK;MACfyB,IAAI,EAAE;KACP;IACDzB,QAAQ,EAAEV,gBAAgB,CAACU,QAAQ,EAAE;MACnC0B,QAAQ,EAAEpB,IAAI,IAAIJ,SAAS,KAAK,WAAW;MAC3CyB,YAAY,EAAE;QACZ,aAAa,EAAE,MAAM;QACrBb,OAAO,EAAEJ;;KAEZ,CAAC;IACFe,IAAI,EAAEpC,qBAAqB,CAACY,EAAE,aAAFA,EAAE,cAAFA,EAAE,GAAI,KAAK,EAAE;MACvC2B,QAAQ,EAAE,CAAC,CAAC;MACZ,YAAY,EAAE1B,SAAS,KAAK,WAAW;MACvC2B,IAAI,EAAE3B,SAAS,KAAK,OAAO,GAAG,aAAa,GAAG,QAAQ;MACtD,iBAAiB,EAAEJ,KAAK,CAAC,YAAY,CAAC,GAAGgC,SAAS,GAAGtB,aAAa;MAClE,GAAGV,KAAK;MACR,GAAGuB,eAAe;MAClBF,SAAS,EAAED,aAAa;MACxBnB,GAAG,EAAEP,aAAa,CAACO,GAAG,EAAEM,SAAS;KAClC;GACF;AACH,CAAC"}
1
+ {"version":3,"names":["React","getNativeElementProps","resolveShorthand","useEventCallback","useMergedRefs","isResolvedShorthand","useDialogContext_unstable","isEscapeKeyDismiss","useModalAttributes","useDialogSurface_unstable","props","ref","backdrop","as","modalType","ctx","inertTrapFocus","dialogRef","open","requestOpenChange","dialogTitleID","dialogTitleId","handledBackdropClick","event","_props_backdrop","_props_backdrop_onClick","onClick","call","isDefaultPrevented","type","handleKeyDown","_props_onKeyDown","onKeyDown","stopPropagation","modalAttributes","trapFocus","legacyTrapFocus","components","root","required","defaultProps","tabIndex","role","undefined"],"sources":["../../../src/components/DialogSurface/useDialogSurface.ts"],"sourcesContent":["import * as React from 'react';\nimport {\n getNativeElementProps,\n resolveShorthand,\n useEventCallback,\n useMergedRefs,\n isResolvedShorthand,\n} from '@fluentui/react-utilities';\nimport type {\n DialogSurfaceElement,\n DialogSurfaceElementIntersection,\n DialogSurfaceProps,\n DialogSurfaceState,\n} from './DialogSurface.types';\nimport { useDialogContext_unstable } from '../../contexts';\nimport { isEscapeKeyDismiss } from '../../utils';\nimport { useModalAttributes } from '@fluentui/react-tabster';\n\n/**\n * Create the state required to render DialogSurface.\n *\n * The returned state can be modified with hooks such as useDialogSurfaceStyles_unstable,\n * before being passed to renderDialogSurface_unstable.\n *\n * @param props - props from this instance of DialogSurface\n * @param ref - reference to root HTMLElement of DialogSurface\n */\nexport const useDialogSurface_unstable = (\n props: DialogSurfaceProps,\n ref: React.Ref<DialogSurfaceElement>,\n): DialogSurfaceState => {\n const { backdrop, as } = props;\n const modalType = useDialogContext_unstable(ctx => ctx.modalType);\n const inertTrapFocus = useDialogContext_unstable(ctx => ctx.inertTrapFocus);\n const dialogRef = useDialogContext_unstable(ctx => ctx.dialogRef);\n const open = useDialogContext_unstable(ctx => ctx.open);\n const requestOpenChange = useDialogContext_unstable(ctx => ctx.requestOpenChange);\n const dialogTitleID = useDialogContext_unstable(ctx => ctx.dialogTitleId);\n\n const handledBackdropClick = useEventCallback((event: React.MouseEvent<HTMLDivElement>) => {\n if (isResolvedShorthand(props.backdrop)) {\n props.backdrop.onClick?.(event);\n }\n if (modalType === 'modal' && !event.isDefaultPrevented()) {\n requestOpenChange({\n event,\n open: false,\n type: 'backdropClick',\n });\n }\n });\n\n const handleKeyDown = useEventCallback((event: React.KeyboardEvent<DialogSurfaceElementIntersection>) => {\n props.onKeyDown?.(event);\n\n if (isEscapeKeyDismiss(event, modalType)) {\n requestOpenChange({\n event,\n open: false,\n type: 'escapeKeyDown',\n });\n // stop propagation to avoid conflicting with other elements that listen for `Escape`\n // e,g: nested Dialog, Popover, Menu and Tooltip\n event.stopPropagation();\n }\n });\n\n const { modalAttributes } = useModalAttributes({\n trapFocus: modalType !== 'non-modal',\n legacyTrapFocus: !inertTrapFocus,\n });\n\n return {\n components: {\n backdrop: 'div',\n root: 'div',\n },\n backdrop: resolveShorthand(backdrop, {\n required: open && modalType !== 'non-modal',\n defaultProps: {\n 'aria-hidden': 'true',\n onClick: handledBackdropClick,\n },\n }),\n root: getNativeElementProps(as ?? 'div', {\n tabIndex: -1, // https://github.com/microsoft/fluentui/issues/25150\n 'aria-modal': modalType !== 'non-modal',\n role: modalType === 'alert' ? 'alertdialog' : 'dialog',\n 'aria-labelledby': props['aria-label'] ? undefined : dialogTitleID,\n ...props,\n ...modalAttributes,\n onKeyDown: handleKeyDown,\n ref: useMergedRefs(ref, dialogRef),\n }),\n };\n};\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SACEC,qBAAqB,EACrBC,gBAAgB,EAChBC,gBAAgB,EAChBC,aAAa,EACbC,mBAAmB,QACd;AAOP,SAASC,yBAAyB,QAAQ;AAC1C,SAASC,kBAAkB,QAAQ;AACnC,SAASC,kBAAkB,QAAQ;AAEnC;;;;;;;;;AASA,OAAO,MAAMC,yBAAA,GAA4BA,CACvCC,KAAA,EACAC,GAAA,KACuB;EACvB,MAAM;IAAEC,QAAA;IAAUC;EAAE,CAAE,GAAGH,KAAA;EACzB,MAAMI,SAAA,GAAYR,yBAAA,CAA0BS,GAAA,IAAOA,GAAA,CAAID,SAAS;EAChE,MAAME,cAAA,GAAiBV,yBAAA,CAA0BS,GAAA,IAAOA,GAAA,CAAIC,cAAc;EAC1E,MAAMC,SAAA,GAAYX,yBAAA,CAA0BS,GAAA,IAAOA,GAAA,CAAIE,SAAS;EAChE,MAAMC,IAAA,GAAOZ,yBAAA,CAA0BS,GAAA,IAAOA,GAAA,CAAIG,IAAI;EACtD,MAAMC,iBAAA,GAAoBb,yBAAA,CAA0BS,GAAA,IAAOA,GAAA,CAAII,iBAAiB;EAChF,MAAMC,aAAA,GAAgBd,yBAAA,CAA0BS,GAAA,IAAOA,GAAA,CAAIM,aAAa;EAExE,MAAMC,oBAAA,GAAuBnB,gBAAA,CAAkBoB,KAAA,IAA4C;IACzF,IAAIlB,mBAAA,CAAoBK,KAAA,CAAME,QAAQ,GAAG;UACvCY,eAAA,EAAAC,uBAAA;MAAA,CAAAA,uBAAA,IAAAD,eAAA,GAAAd,KAAA,CAAME,QAAQ,EAACc,OAAO,cAAtBD,uBAAA,uBAAAA,uBAAA,CAAAE,IAAA,CAAAH,eAAA,EAAyBD,KAAA;IAC3B;IACA,IAAIT,SAAA,KAAc,WAAW,CAACS,KAAA,CAAMK,kBAAkB,IAAI;MACxDT,iBAAA,CAAkB;QAChBI,KAAA;QACAL,IAAA,EAAM,KAAK;QACXW,IAAA,EAAM;MACR;IACF;EACF;EAEA,MAAMC,aAAA,GAAgB3B,gBAAA,CAAkBoB,KAAA,IAAiE;QACvGQ,gBAAA;IAAA,CAAAA,gBAAA,GAAArB,KAAA,CAAMsB,SAAS,cAAfD,gBAAA,uBAAAA,gBAAA,CAAAJ,IAAA,CAAAjB,KAAA,EAAkBa,KAAA;IAElB,IAAIhB,kBAAA,CAAmBgB,KAAA,EAAOT,SAAA,GAAY;MACxCK,iBAAA,CAAkB;QAChBI,KAAA;QACAL,IAAA,EAAM,KAAK;QACXW,IAAA,EAAM;MACR;MACA;MACA;MACAN,KAAA,CAAMU,eAAe;IACvB;EACF;EAEA,MAAM;IAAEC;EAAe,CAAE,GAAG1B,kBAAA,CAAmB;IAC7C2B,SAAA,EAAWrB,SAAA,KAAc;IACzBsB,eAAA,EAAiB,CAACpB;EACpB;EAEA,OAAO;IACLqB,UAAA,EAAY;MACVzB,QAAA,EAAU;MACV0B,IAAA,EAAM;IACR;IACA1B,QAAA,EAAUV,gBAAA,CAAiBU,QAAA,EAAU;MACnC2B,QAAA,EAAUrB,IAAA,IAAQJ,SAAA,KAAc;MAChC0B,YAAA,EAAc;QACZ,eAAe;QACfd,OAAA,EAASJ;MACX;IACF;IACAgB,IAAA,EAAMrC,qBAAA,CAAsBY,EAAA,aAAAA,EAAA,cAAAA,EAAA,GAAM,KAAK,EAAE;MACvC4B,QAAA,EAAU,CAAC;MACX,cAAc3B,SAAA,KAAc;MAC5B4B,IAAA,EAAM5B,SAAA,KAAc,UAAU,gBAAgB,QAAQ;MACtD,mBAAmBJ,KAAK,CAAC,aAAa,GAAGiC,SAAA,GAAYvB,aAAa;MAClE,GAAGV,KAAK;MACR,GAAGwB,eAAe;MAClBF,SAAA,EAAWF,aAAA;MACXnB,GAAA,EAAKP,aAAA,CAAcO,GAAA,EAAKM,SAAA;IAC1B;EACF;AACF"}
@@ -1 +1 @@
1
- {"version":3,"names":["useDialogSurfaceContextValues_unstable","state","dialogSurface"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogSurface/useDialogSurfaceContextValues.ts"],"sourcesContent":["import type { DialogSurfaceContextValues, DialogSurfaceState } from './DialogSurface.types';\nimport type { DialogSurfaceContextValue } from '../../contexts';\n\nexport function useDialogSurfaceContextValues_unstable(state: DialogSurfaceState): DialogSurfaceContextValues {\n const dialogSurface: DialogSurfaceContextValue = true;\n\n return { dialogSurface };\n}\n"],"mappings":"AAGA,OAAM,SAAUA,sCAAsCA,CAACC,KAAyB;EAC9E,MAAMC,aAAa,GAA8B,IAAI;EAErD,OAAO;IAAEA;EAAa,CAAE;AAC1B"}
1
+ {"version":3,"names":["useDialogSurfaceContextValues_unstable","state","dialogSurface"],"sources":["../../../src/components/DialogSurface/useDialogSurfaceContextValues.ts"],"sourcesContent":["import type { DialogSurfaceContextValues, DialogSurfaceState } from './DialogSurface.types';\nimport type { DialogSurfaceContextValue } from '../../contexts';\n\nexport function useDialogSurfaceContextValues_unstable(state: DialogSurfaceState): DialogSurfaceContextValues {\n const dialogSurface: DialogSurfaceContextValue = true;\n\n return { dialogSurface };\n}\n"],"mappings":"AAGA,OAAO,SAASA,uCAAuCC,KAAyB,EAA8B;EAC5G,MAAMC,aAAA,GAA2C,IAAI;EAErD,OAAO;IAAEA;EAAc;AACzB"}
@@ -1 +1 @@
1
- {"version":3,"names":["__styles","mergeClasses","shorthands","tokens","createFocusOutlineStyle","MEDIA_QUERY_BREAKPOINT_SELECTOR","SURFACE_BORDER_WIDTH","SURFACE_PADDING","useDialogContext_unstable","dialogSurfaceClassNames","root","backdrop","useStyles","focusOutline","Brovlpu","B486eqv","B8q5s1w","Bci5o5g","n8qw10","Bdrgwmp","Bm4h7ae","B7ys5i9","Busjfv9","Bhk32uz","Bf4ptjt","kclons","Bhdgwq3","Blkhhs4","Bqtpl0w","clg4pj","hgwjuy","Bonggc9","B1tsrr9","Dah5zi","Bkh64rk","qqdqy8","B6dhp37","i03rao","Boxcth7","Bsom6fd","J0r882","Bjwuhne","Ghsupd","Bule8hv","mc9l5x","famaaq","Bcdw1i0","Bhzewxz","j35jbq","B5kzvoi","oyh7mz","z8tnut","z189sj","Byoj8tv","uwmqm3","B6of3ja","t21cq0","jrapky","Frg6f3","icvyot","vrafjx","oivjwe","wvpqe5","B68tc82","Bmxbyg5","fshzfu","qhf8xq","a9b677","Bqenvij","B2u0y6b","Bxyxcbc","B7ck84d","E5pizo","De3pzq","sj55zd","B4j52fo","Bekrc4i","Bn0qgzm","ibv6hh","g2u3we","h3c5rm","B9xav0g","zhjwy3","Bbmb7ep","Beyfa6y","B7oj6ja","Btl43ni","B5xtmjs","nestedDialogBackdrop","nestedNativeDialogBackdrop","f","i","d","m","useDialogSurfaceStyles_unstable","state","styles","isNestedDialog","ctx","className"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogSurface/useDialogSurfaceStyles.ts"],"sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\nimport { tokens } from '@fluentui/react-theme';\nimport { createFocusOutlineStyle } from '@fluentui/react-tabster';\nimport {\n MEDIA_QUERY_BREAKPOINT_SELECTOR,\n SURFACE_BORDER_WIDTH,\n SURFACE_PADDING,\n useDialogContext_unstable,\n} from '../../contexts';\nimport type { DialogSurfaceSlots, DialogSurfaceState } from './DialogSurface.types';\n\nexport const dialogSurfaceClassNames: SlotClassNames<DialogSurfaceSlots> = {\n root: 'fui-DialogSurface',\n backdrop: 'fui-DialogSurface__backdrop',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n focusOutline: createFocusOutlineStyle(),\n root: {\n display: 'block',\n userSelect: 'unset',\n visibility: 'unset',\n ...shorthands.inset(0),\n ...shorthands.padding(0),\n ...shorthands.padding(SURFACE_PADDING),\n ...shorthands.margin('auto'),\n ...shorthands.borderStyle('none'),\n ...shorthands.overflow('unset'),\n '&::backdrop': {\n backgroundColor: 'rgba(0, 0, 0, 0.4)',\n },\n position: 'fixed',\n width: '100%',\n height: 'fit-content',\n maxWidth: '600px',\n maxHeight: '100vh',\n boxSizing: 'border-box',\n boxShadow: tokens.shadow64,\n backgroundColor: tokens.colorNeutralBackground1,\n color: tokens.colorNeutralForeground1,\n ...shorthands.border(SURFACE_BORDER_WIDTH, 'solid', tokens.colorTransparentStroke),\n ...shorthands.borderRadius(tokens.borderRadiusXLarge),\n [MEDIA_QUERY_BREAKPOINT_SELECTOR]: {\n maxWidth: '100vw',\n },\n },\n backdrop: {\n position: 'fixed',\n backgroundColor: 'rgba(0, 0, 0, 0.4)',\n ...shorthands.inset('0px'),\n },\n nestedDialogBackdrop: {\n backgroundColor: 'transparent',\n },\n nestedNativeDialogBackdrop: {\n '&::backdrop': {\n backgroundColor: 'transparent',\n },\n },\n});\n\n/**\n * Apply styling to the DialogSurface slots based on the state\n */\nexport const useDialogSurfaceStyles_unstable = (state: DialogSurfaceState): DialogSurfaceState => {\n const styles = useStyles();\n const isNestedDialog = useDialogContext_unstable(ctx => ctx.isNestedDialog);\n\n state.root.className = mergeClasses(\n dialogSurfaceClassNames.root,\n styles.root,\n styles.focusOutline,\n isNestedDialog && styles.nestedNativeDialogBackdrop,\n state.root.className,\n );\n if (state.backdrop) {\n state.backdrop.className = mergeClasses(\n dialogSurfaceClassNames.backdrop,\n styles.backdrop,\n isNestedDialog && styles.nestedDialogBackdrop,\n state.backdrop.className,\n );\n }\n return state;\n};\n"],"mappings":"AAAA,SAAAA,QAAA,EAAqBC,YAAY,EAAEC,UAAU,QAAQ,gBAAgB;AAErE,SAASC,MAAM,QAAQ,uBAAuB;AAC9C,SAASC,uBAAuB,QAAQ,yBAAyB;AACjE,SACEC,+BAA+B,EAC/BC,oBAAoB,EACpBC,eAAe,EACfC,yBAAyB,QACpB,gBAAgB;AAGvB,OAAO,MAAMC,uBAAuB,GAAuC;EACzEC,IAAI,EAAE,mBAAmB;EACzBC,QAAQ,EAAE;CACX;AAED;;;AAGA,MAAMC,SAAS,gBAAGZ,QAAA;EAAAa,YAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;EAAAjC,IAAA;IAAAkC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;EAAA;EAAA5E,QAAA;IAAAuD,MAAA;IAAAO,MAAA;IAAA1B,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;EAAA;EAAAsC,oBAAA;IAAAf,MAAA;EAAA;EAAAgB,0BAAA;IAAAxB,MAAA;EAAA;AAAA;EAAAyB,CAAA;EAAAC,CAAA;EAAAC,CAAA;EAAAC,CAAA;IAAAA,CAAA;EAAA;AAAA,EA2ChB;AAEF;;;AAGA,OAAO,MAAMC,+BAA+B,GAAIC,KAAyB,IAAwB;EAC/F,MAAMC,MAAM,GAAGpF,SAAS,EAAE;EAC1B,MAAMqF,cAAc,GAAGzF,yBAAyB,CAAC0F,GAAG,IAAIA,GAAG,CAACD,cAAc,CAAC;EAE3EF,KAAK,CAACrF,IAAI,CAACyF,SAAS,GAAGlG,YAAY,CACjCQ,uBAAuB,CAACC,IAAI,EAC5BsF,MAAM,CAACtF,IAAI,EACXsF,MAAM,CAACnF,YAAY,EACnBoF,cAAc,IAAID,MAAM,CAACP,0BAA0B,EACnDM,KAAK,CAACrF,IAAI,CAACyF,SAAS,CACrB;EACD,IAAIJ,KAAK,CAACpF,QAAQ,EAAE;IAClBoF,KAAK,CAACpF,QAAQ,CAACwF,SAAS,GAAGlG,YAAY,CACrCQ,uBAAuB,CAACE,QAAQ,EAChCqF,MAAM,CAACrF,QAAQ,EACfsF,cAAc,IAAID,MAAM,CAACR,oBAAoB,EAC7CO,KAAK,CAACpF,QAAQ,CAACwF,SAAS,CACzB;;EAEH,OAAOJ,KAAK;AACd,CAAC"}
1
+ {"version":3,"names":["__styles","mergeClasses","shorthands","tokens","createFocusOutlineStyle","MEDIA_QUERY_BREAKPOINT_SELECTOR","SURFACE_BORDER_WIDTH","SURFACE_PADDING","useDialogContext_unstable","dialogSurfaceClassNames","root","backdrop","useStyles","focusOutline","Brovlpu","B486eqv","B8q5s1w","Bci5o5g","n8qw10","Bdrgwmp","Bm4h7ae","B7ys5i9","Busjfv9","Bhk32uz","Bf4ptjt","kclons","Bhdgwq3","Blkhhs4","Bqtpl0w","clg4pj","hgwjuy","Bonggc9","B1tsrr9","Dah5zi","Bkh64rk","qqdqy8","B6dhp37","i03rao","Boxcth7","Bsom6fd","J0r882","Bjwuhne","Ghsupd","Bule8hv","mc9l5x","famaaq","Bcdw1i0","Bhzewxz","j35jbq","B5kzvoi","oyh7mz","z8tnut","z189sj","Byoj8tv","uwmqm3","B6of3ja","t21cq0","jrapky","Frg6f3","icvyot","vrafjx","oivjwe","wvpqe5","B68tc82","Bmxbyg5","fshzfu","qhf8xq","a9b677","Bqenvij","B2u0y6b","Bxyxcbc","B7ck84d","E5pizo","De3pzq","sj55zd","B4j52fo","Bekrc4i","Bn0qgzm","ibv6hh","g2u3we","h3c5rm","B9xav0g","zhjwy3","Bbmb7ep","Beyfa6y","B7oj6ja","Btl43ni","B5xtmjs","nestedDialogBackdrop","nestedNativeDialogBackdrop","f","i","d","m","useDialogSurfaceStyles_unstable","state","styles","isNestedDialog","ctx","className"],"sources":["../../../src/components/DialogSurface/useDialogSurfaceStyles.ts"],"sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\nimport { tokens } from '@fluentui/react-theme';\nimport { createFocusOutlineStyle } from '@fluentui/react-tabster';\nimport {\n MEDIA_QUERY_BREAKPOINT_SELECTOR,\n SURFACE_BORDER_WIDTH,\n SURFACE_PADDING,\n useDialogContext_unstable,\n} from '../../contexts';\nimport type { DialogSurfaceSlots, DialogSurfaceState } from './DialogSurface.types';\n\nexport const dialogSurfaceClassNames: SlotClassNames<DialogSurfaceSlots> = {\n root: 'fui-DialogSurface',\n backdrop: 'fui-DialogSurface__backdrop',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n focusOutline: createFocusOutlineStyle(),\n root: {\n display: 'block',\n userSelect: 'unset',\n visibility: 'unset',\n ...shorthands.inset(0),\n ...shorthands.padding(0),\n ...shorthands.padding(SURFACE_PADDING),\n ...shorthands.margin('auto'),\n ...shorthands.borderStyle('none'),\n ...shorthands.overflow('unset'),\n '&::backdrop': {\n backgroundColor: 'rgba(0, 0, 0, 0.4)',\n },\n position: 'fixed',\n width: '100%',\n height: 'fit-content',\n maxWidth: '600px',\n maxHeight: '100vh',\n boxSizing: 'border-box',\n boxShadow: tokens.shadow64,\n backgroundColor: tokens.colorNeutralBackground1,\n color: tokens.colorNeutralForeground1,\n ...shorthands.border(SURFACE_BORDER_WIDTH, 'solid', tokens.colorTransparentStroke),\n ...shorthands.borderRadius(tokens.borderRadiusXLarge),\n [MEDIA_QUERY_BREAKPOINT_SELECTOR]: {\n maxWidth: '100vw',\n },\n },\n backdrop: {\n position: 'fixed',\n backgroundColor: 'rgba(0, 0, 0, 0.4)',\n ...shorthands.inset('0px'),\n },\n nestedDialogBackdrop: {\n backgroundColor: 'transparent',\n },\n nestedNativeDialogBackdrop: {\n '&::backdrop': {\n backgroundColor: 'transparent',\n },\n },\n});\n\n/**\n * Apply styling to the DialogSurface slots based on the state\n */\nexport const useDialogSurfaceStyles_unstable = (state: DialogSurfaceState): DialogSurfaceState => {\n const styles = useStyles();\n const isNestedDialog = useDialogContext_unstable(ctx => ctx.isNestedDialog);\n\n state.root.className = mergeClasses(\n dialogSurfaceClassNames.root,\n styles.root,\n styles.focusOutline,\n isNestedDialog && styles.nestedNativeDialogBackdrop,\n state.root.className,\n );\n if (state.backdrop) {\n state.backdrop.className = mergeClasses(\n dialogSurfaceClassNames.backdrop,\n styles.backdrop,\n isNestedDialog && styles.nestedDialogBackdrop,\n state.backdrop.className,\n );\n }\n return state;\n};\n"],"mappings":"AAAA,SAAAA,QAAA,EAAqBC,YAAY,EAAEC,UAAU,QAAQ;AAErD,SAASC,MAAM,QAAQ;AACvB,SAASC,uBAAuB,QAAQ;AACxC,SACEC,+BAA+B,EAC/BC,oBAAoB,EACpBC,eAAe,EACfC,yBAAyB,QACpB;AAGP,OAAO,MAAMC,uBAAA,GAA8D;EACzEC,IAAA,EAAM;EACNC,QAAA,EAAU;AACZ;AAEA;;;AAGA,MAAMC,SAAA,gBAAYZ,QAAA;EAAAa,YAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;EAAAjC,IAAA;IAAAkC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;EAAA;EAAA5E,QAAA;IAAAuD,MAAA;IAAAO,MAAA;IAAA1B,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;EAAA;EAAAsC,oBAAA;IAAAf,MAAA;EAAA;EAAAgB,0BAAA;IAAAxB,MAAA;EAAA;AAAA;EAAAyB,CAAA;EAAAC,CAAA;EAAAC,CAAA;EAAAC,CAAA;IAAAA,CAAA;EAAA;AAAA,EA2ClB;AAEA;;;AAGA,OAAO,MAAMC,+BAAA,GAAmCC,KAAA,IAAkD;EAChG,MAAMC,MAAA,GAASpF,SAAA;EACf,MAAMqF,cAAA,GAAiBzF,yBAAA,CAA0B0F,GAAA,IAAOA,GAAA,CAAID,cAAc;EAE1EF,KAAA,CAAMrF,IAAI,CAACyF,SAAS,GAAGlG,YAAA,CACrBQ,uBAAA,CAAwBC,IAAI,EAC5BsF,MAAA,CAAOtF,IAAI,EACXsF,MAAA,CAAOnF,YAAY,EACnBoF,cAAA,IAAkBD,MAAA,CAAOP,0BAA0B,EACnDM,KAAA,CAAMrF,IAAI,CAACyF,SAAS;EAEtB,IAAIJ,KAAA,CAAMpF,QAAQ,EAAE;IAClBoF,KAAA,CAAMpF,QAAQ,CAACwF,SAAS,GAAGlG,YAAA,CACzBQ,uBAAA,CAAwBE,QAAQ,EAChCqF,MAAA,CAAOrF,QAAQ,EACfsF,cAAA,IAAkBD,MAAA,CAAOR,oBAAoB,EAC7CO,KAAA,CAAMpF,QAAQ,CAACwF,SAAS;EAE5B;EACA,OAAOJ,KAAA;AACT"}
@@ -1 +1 @@
1
- {"version":3,"names":["React","useDialogTitle_unstable","renderDialogTitle_unstable","useDialogTitleStyles_unstable","useCustomStyleHooks_unstable","DialogTitle","forwardRef","props","ref","state","useCustomStyles","displayName"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogTitle/DialogTitle.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useDialogTitle_unstable } from './useDialogTitle';\nimport { renderDialogTitle_unstable } from './renderDialogTitle';\nimport { useDialogTitleStyles_unstable } from './useDialogTitleStyles';\nimport type { DialogTitleProps } from './DialogTitle.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useCustomStyleHooks_unstable } from '@fluentui/react-shared-contexts';\n\n/**\n * The `DialogTitle` component expects to have a title/header\n * and when `Dialog` is `non-modal` a close (X icon) button is provided through `action` slot by default.\n */\nexport const DialogTitle: ForwardRefComponent<DialogTitleProps> = React.forwardRef((props, ref) => {\n const state = useDialogTitle_unstable(props, ref);\n\n useDialogTitleStyles_unstable(state);\n\n const { useDialogTitleStyles_unstable: useCustomStyles } = useCustomStyleHooks_unstable();\n useCustomStyles(state);\n\n return renderDialogTitle_unstable(state);\n});\n\nDialogTitle.displayName = 'DialogTitle';\n"],"mappings":"AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,SAASC,uBAAuB,QAAQ,kBAAkB;AAC1D,SAASC,0BAA0B,QAAQ,qBAAqB;AAChE,SAASC,6BAA6B,QAAQ,wBAAwB;AAGtE,SAASC,4BAA4B,QAAQ,iCAAiC;AAE9E;;;;AAIA,OAAO,MAAMC,WAAW,gBAA0CL,KAAK,CAACM,UAAU,CAAC,CAACC,KAAK,EAAEC,GAAG,KAAI;EAChG,MAAMC,KAAK,GAAGR,uBAAuB,CAACM,KAAK,EAAEC,GAAG,CAAC;EAEjDL,6BAA6B,CAACM,KAAK,CAAC;EAEpC,MAAM;IAAEN,6BAA6B,EAAEO;EAAe,CAAE,GAAGN,4BAA4B,EAAE;EACzFM,eAAe,CAACD,KAAK,CAAC;EAEtB,OAAOP,0BAA0B,CAACO,KAAK,CAAC;AAC1C,CAAC,CAAC;AAEFJ,WAAW,CAACM,WAAW,GAAG,aAAa"}
1
+ {"version":3,"names":["React","useDialogTitle_unstable","renderDialogTitle_unstable","useDialogTitleStyles_unstable","useCustomStyleHooks_unstable","DialogTitle","forwardRef","props","ref","state","useCustomStyles","displayName"],"sources":["../../../src/components/DialogTitle/DialogTitle.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useDialogTitle_unstable } from './useDialogTitle';\nimport { renderDialogTitle_unstable } from './renderDialogTitle';\nimport { useDialogTitleStyles_unstable } from './useDialogTitleStyles';\nimport type { DialogTitleProps } from './DialogTitle.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useCustomStyleHooks_unstable } from '@fluentui/react-shared-contexts';\n\n/**\n * The `DialogTitle` component expects to have a title/header\n * and when `Dialog` is `non-modal` a close (X icon) button is provided through `action` slot by default.\n */\nexport const DialogTitle: ForwardRefComponent<DialogTitleProps> = React.forwardRef((props, ref) => {\n const state = useDialogTitle_unstable(props, ref);\n\n useDialogTitleStyles_unstable(state);\n\n const { useDialogTitleStyles_unstable: useCustomStyles } = useCustomStyleHooks_unstable();\n useCustomStyles(state);\n\n return renderDialogTitle_unstable(state);\n});\n\nDialogTitle.displayName = 'DialogTitle';\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SAASC,uBAAuB,QAAQ;AACxC,SAASC,0BAA0B,QAAQ;AAC3C,SAASC,6BAA6B,QAAQ;AAG9C,SAASC,4BAA4B,QAAQ;AAE7C;;;;AAIA,OAAO,MAAMC,WAAA,gBAAqDL,KAAA,CAAMM,UAAU,CAAC,CAACC,KAAA,EAAOC,GAAA,KAAQ;EACjG,MAAMC,KAAA,GAAQR,uBAAA,CAAwBM,KAAA,EAAOC,GAAA;EAE7CL,6BAAA,CAA8BM,KAAA;EAE9B,MAAM;IAAEN,6BAAA,EAA+BO;EAAe,CAAE,GAAGN,4BAAA;EAC3DM,eAAA,CAAgBD,KAAA;EAEhB,OAAOP,0BAAA,CAA2BO,KAAA;AACpC;AAEAJ,WAAA,CAAYM,WAAW,GAAG"}
@@ -1 +1 @@
1
- {"version":3,"file":"DialogTitle.types.js","sourceRoot":"../src/","sources":["packages/react-components/react-dialog/src/components/DialogTitle/DialogTitle.types.ts"],"names":[],"mappings":"","sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\n\nexport type DialogTitleSlots = {\n /**\n * By default this is a div, but can be a heading.\n */\n root: Slot<'div', 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'>;\n /**\n * By default a Dialog with modalType='non-modal' will have a close button action\n */\n action?: Slot<'div'>;\n};\n\n/**\n * DialogTitle Props\n */\nexport type DialogTitleProps = ComponentProps<DialogTitleSlots>;\n\n/**\n * State used in rendering DialogTitle\n */\nexport type DialogTitleState = ComponentState<DialogTitleSlots>;\n"]}
1
+ {"version":3,"names":[],"sources":["../../../src/components/DialogTitle/DialogTitle.types.ts"],"sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\n\nexport type DialogTitleSlots = {\n /**\n * By default this is a div, but can be a heading.\n */\n root: Slot<'div', 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'>;\n /**\n * By default a Dialog with modalType='non-modal' will have a close button action\n */\n action?: Slot<'div'>;\n};\n\n/**\n * DialogTitle Props\n */\nexport type DialogTitleProps = ComponentProps<DialogTitleSlots>;\n\n/**\n * State used in rendering DialogTitle\n */\nexport type DialogTitleState = ComponentState<DialogTitleSlots>;\n"],"mappings":"AAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["packages/react-components/react-dialog/src/components/DialogTitle/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,kBAAkB,CAAC;AACjC,cAAc,wBAAwB,CAAC","sourcesContent":["export * from './DialogTitle';\nexport * from './DialogTitle.types';\nexport * from './renderDialogTitle';\nexport * from './useDialogTitle';\nexport * from './useDialogTitleStyles';\n"]}
1
+ {"version":3,"names":[],"sources":["../../../src/components/DialogTitle/index.ts"],"sourcesContent":["export * from './DialogTitle';\nexport * from './DialogTitle.types';\nexport * from './renderDialogTitle';\nexport * from './useDialogTitle';\nexport * from './useDialogTitleStyles';\n"],"mappings":"AAAA,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc"}
@@ -8,10 +8,6 @@ export const renderDialogTitle_unstable = state => {
8
8
  slots,
9
9
  slotProps
10
10
  } = getSlots(state);
11
- return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(slots.root, {
12
- ...slotProps.root
13
- }, slotProps.root.children), slots.action && /*#__PURE__*/React.createElement(slots.action, {
14
- ...slotProps.action
15
- }));
11
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(slots.root, slotProps.root, slotProps.root.children), slots.action && /*#__PURE__*/React.createElement(slots.action, slotProps.action));
16
12
  };
17
13
  //# sourceMappingURL=renderDialogTitle.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["React","getSlots","renderDialogTitle_unstable","state","slots","slotProps","createElement","Fragment","root","children","action"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogTitle/renderDialogTitle.tsx"],"sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { DialogTitleState, DialogTitleSlots } from './DialogTitle.types';\n\n/**\n * Render the final JSX of DialogTitle\n */\nexport const renderDialogTitle_unstable = (state: DialogTitleState) => {\n const { slots, slotProps } = getSlots<DialogTitleSlots>(state);\n\n return (\n <>\n <slots.root {...slotProps.root}>{slotProps.root.children}</slots.root>\n {slots.action && <slots.action {...slotProps.action} />}\n </>\n );\n};\n"],"mappings":"AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,SAASC,QAAQ,QAAQ,2BAA2B;AAGpD;;;AAGA,OAAO,MAAMC,0BAA0B,GAAIC,KAAuB,IAAI;EACpE,MAAM;IAAEC,KAAK;IAAEC;EAAS,CAAE,GAAGJ,QAAQ,CAAmBE,KAAK,CAAC;EAE9D,oBACEH,KAAA,CAAAM,aAAA,CAAAN,KAAA,CAAAO,QAAA,qBACEP,KAAA,CAAAM,aAAA,CAACF,KAAK,CAACI,IAAI;IAAA,GAAKH,SAAS,CAACG;EAAI,GAAGH,SAAS,CAACG,IAAI,CAACC,QAAQ,CAAc,EACrEL,KAAK,CAACM,MAAM,iBAAIV,KAAA,CAAAM,aAAA,CAACF,KAAK,CAACM,MAAM;IAAA,GAAKL,SAAS,CAACK;EAAM,EAAI,CACtD;AAEP,CAAC"}
1
+ {"version":3,"names":["React","getSlots","renderDialogTitle_unstable","state","slots","slotProps","createElement","Fragment","root","children","action"],"sources":["../../../src/components/DialogTitle/renderDialogTitle.tsx"],"sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { DialogTitleState, DialogTitleSlots } from './DialogTitle.types';\n\n/**\n * Render the final JSX of DialogTitle\n */\nexport const renderDialogTitle_unstable = (state: DialogTitleState) => {\n const { slots, slotProps } = getSlots<DialogTitleSlots>(state);\n\n return (\n <>\n <slots.root {...slotProps.root}>{slotProps.root.children}</slots.root>\n {slots.action && <slots.action {...slotProps.action} />}\n </>\n );\n};\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SAASC,QAAQ,QAAQ;AAGzB;;;AAGA,OAAO,MAAMC,0BAAA,GAA8BC,KAAA,IAA4B;EACrE,MAAM;IAAEC,KAAA;IAAOC;EAAS,CAAE,GAAGJ,QAAA,CAA2BE,KAAA;EAExD,oBACEH,KAAA,CAAAM,aAAA,CAAAN,KAAA,CAAAO,QAAA,qBACEP,KAAA,CAAAM,aAAA,CAACF,KAAA,CAAMI,IAAI,EAAKH,SAAA,CAAUG,IAAI,EAAGH,SAAA,CAAUG,IAAI,CAACC,QAAQ,GACvDL,KAAA,CAAMM,MAAM,iBAAIV,KAAA,CAAAM,aAAA,CAACF,KAAA,CAAMM,MAAM,EAAKL,SAAA,CAAUK,MAAM;AAGzD"}
@@ -38,7 +38,9 @@ export const useDialogTitle_unstable = (props, ref) => {
38
38
  disableButtonEnhancement: true,
39
39
  action: "close"
40
40
  }, /*#__PURE__*/React.createElement("button", {
41
+ type: "button",
41
42
  className: internalStyles.button,
43
+ // TODO: find a better way to add internal labels
42
44
  "aria-label": "close"
43
45
  }, /*#__PURE__*/React.createElement(Dismiss24Regular, null)))
44
46
  }
@@ -1 +1 @@
1
- {"version":3,"names":["React","getNativeElementProps","useDialogContext_unstable","Dismiss24Regular","resolveShorthand","DialogTrigger","useDialogTitleInternalStyles","useDialogTitle_unstable","props","ref","as","action","modalType","ctx","internalStyles","components","root","id","dialogTitleId","required","defaultProps","children","createElement","disableButtonEnhancement","className","button"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogTitle/useDialogTitle.tsx"],"sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps } from '@fluentui/react-utilities';\nimport type { DialogTitleProps, DialogTitleState } from './DialogTitle.types';\nimport { useDialogContext_unstable } from '../../contexts/dialogContext';\nimport { Dismiss24Regular } from '@fluentui/react-icons';\nimport { resolveShorthand } from '@fluentui/react-utilities';\nimport { DialogTrigger } from '../DialogTrigger/DialogTrigger';\nimport { useDialogTitleInternalStyles } from './useDialogTitleStyles';\n\n/**\n * Create the state required to render DialogTitle.\n *\n * The returned state can be modified with hooks such as useDialogTitleStyles_unstable,\n * before being passed to renderDialogTitle_unstable.\n *\n * @param props - props from this instance of DialogTitle\n * @param ref - reference to root HTMLElement of DialogTitle\n */\nexport const useDialogTitle_unstable = (props: DialogTitleProps, ref: React.Ref<HTMLElement>): DialogTitleState => {\n const { as, action } = props;\n const modalType = useDialogContext_unstable(ctx => ctx.modalType);\n const internalStyles = useDialogTitleInternalStyles();\n\n return {\n components: {\n root: 'div',\n action: 'div',\n },\n root: getNativeElementProps(as ?? 'div', {\n ref,\n id: useDialogContext_unstable(ctx => ctx.dialogTitleId),\n ...props,\n }),\n action: resolveShorthand(action, {\n required: modalType === 'non-modal',\n defaultProps: {\n children: (\n <DialogTrigger disableButtonEnhancement action=\"close\">\n <button\n className={internalStyles.button}\n // TODO: find a better way to add internal labels\n aria-label=\"close\"\n >\n <Dismiss24Regular />\n </button>\n </DialogTrigger>\n ),\n },\n }),\n };\n};\n"],"mappings":"AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,SAASC,qBAAqB,QAAQ,2BAA2B;AAEjE,SAASC,yBAAyB,QAAQ,8BAA8B;AACxE,SAASC,gBAAgB,QAAQ,uBAAuB;AACxD,SAASC,gBAAgB,QAAQ,2BAA2B;AAC5D,SAASC,aAAa,QAAQ,gCAAgC;AAC9D,SAASC,4BAA4B,QAAQ,wBAAwB;AAErE;;;;;;;;;AASA,OAAO,MAAMC,uBAAuB,GAAGA,CAACC,KAAuB,EAAEC,GAA2B,KAAsB;EAChH,MAAM;IAAEC,EAAE;IAAEC;EAAM,CAAE,GAAGH,KAAK;EAC5B,MAAMI,SAAS,GAAGV,yBAAyB,CAACW,GAAG,IAAIA,GAAG,CAACD,SAAS,CAAC;EACjE,MAAME,cAAc,GAAGR,4BAA4B,EAAE;EAErD,OAAO;IACLS,UAAU,EAAE;MACVC,IAAI,EAAE,KAAK;MACXL,MAAM,EAAE;KACT;IACDK,IAAI,EAAEf,qBAAqB,CAACS,EAAE,aAAFA,EAAE,cAAFA,EAAE,GAAI,KAAK,EAAE;MACvCD,GAAG;MACHQ,EAAE,EAAEf,yBAAyB,CAACW,GAAG,IAAIA,GAAG,CAACK,aAAa,CAAC;MACvD,GAAGV;KACJ,CAAC;IACFG,MAAM,EAAEP,gBAAgB,CAACO,MAAM,EAAE;MAC/BQ,QAAQ,EAAEP,SAAS,KAAK,WAAW;MACnCQ,YAAY,EAAE;QACZC,QAAQ,eACNrB,KAAA,CAAAsB,aAAA,CAACjB,aAAa;UAACkB,wBAAwB;UAACZ,MAAM,EAAC;QAAO,gBACpDX,KAAA,CAAAsB,aAAA;UACEE,SAAS,EAAEV,cAAc,CAACW,MAAM;UAAA,cAErB;QAAO,gBAElBzB,KAAA,CAAAsB,aAAA,CAACnB,gBAAgB,OAAG,CACb;;KAIhB;GACF;AACH,CAAC"}
1
+ {"version":3,"names":["React","getNativeElementProps","useDialogContext_unstable","Dismiss24Regular","resolveShorthand","DialogTrigger","useDialogTitleInternalStyles","useDialogTitle_unstable","props","ref","as","action","modalType","ctx","internalStyles","components","root","id","dialogTitleId","required","defaultProps","children","createElement","disableButtonEnhancement","type","className","button"],"sources":["../../../src/components/DialogTitle/useDialogTitle.tsx"],"sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps } from '@fluentui/react-utilities';\nimport type { DialogTitleProps, DialogTitleState } from './DialogTitle.types';\nimport { useDialogContext_unstable } from '../../contexts/dialogContext';\nimport { Dismiss24Regular } from '@fluentui/react-icons';\nimport { resolveShorthand } from '@fluentui/react-utilities';\nimport { DialogTrigger } from '../DialogTrigger/DialogTrigger';\nimport { useDialogTitleInternalStyles } from './useDialogTitleStyles';\n\n/**\n * Create the state required to render DialogTitle.\n *\n * The returned state can be modified with hooks such as useDialogTitleStyles_unstable,\n * before being passed to renderDialogTitle_unstable.\n *\n * @param props - props from this instance of DialogTitle\n * @param ref - reference to root HTMLElement of DialogTitle\n */\nexport const useDialogTitle_unstable = (props: DialogTitleProps, ref: React.Ref<HTMLElement>): DialogTitleState => {\n const { as, action } = props;\n const modalType = useDialogContext_unstable(ctx => ctx.modalType);\n const internalStyles = useDialogTitleInternalStyles();\n\n return {\n components: {\n root: 'div',\n action: 'div',\n },\n root: getNativeElementProps(as ?? 'div', {\n ref,\n id: useDialogContext_unstable(ctx => ctx.dialogTitleId),\n ...props,\n }),\n action: resolveShorthand(action, {\n required: modalType === 'non-modal',\n defaultProps: {\n children: (\n <DialogTrigger disableButtonEnhancement action=\"close\">\n <button\n type=\"button\"\n className={internalStyles.button}\n // TODO: find a better way to add internal labels\n aria-label=\"close\"\n >\n <Dismiss24Regular />\n </button>\n </DialogTrigger>\n ),\n },\n }),\n };\n};\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SAASC,qBAAqB,QAAQ;AAEtC,SAASC,yBAAyB,QAAQ;AAC1C,SAASC,gBAAgB,QAAQ;AACjC,SAASC,gBAAgB,QAAQ;AACjC,SAASC,aAAa,QAAQ;AAC9B,SAASC,4BAA4B,QAAQ;AAE7C;;;;;;;;;AASA,OAAO,MAAMC,uBAAA,GAA0BA,CAACC,KAAA,EAAyBC,GAAA,KAAkD;EACjH,MAAM;IAAEC,EAAA;IAAIC;EAAM,CAAE,GAAGH,KAAA;EACvB,MAAMI,SAAA,GAAYV,yBAAA,CAA0BW,GAAA,IAAOA,GAAA,CAAID,SAAS;EAChE,MAAME,cAAA,GAAiBR,4BAAA;EAEvB,OAAO;IACLS,UAAA,EAAY;MACVC,IAAA,EAAM;MACNL,MAAA,EAAQ;IACV;IACAK,IAAA,EAAMf,qBAAA,CAAsBS,EAAA,aAAAA,EAAA,cAAAA,EAAA,GAAM,KAAK,EAAE;MACvCD,GAAA;MACAQ,EAAA,EAAIf,yBAAA,CAA0BW,GAAA,IAAOA,GAAA,CAAIK,aAAa;MACtD,GAAGV;IACL;IACAG,MAAA,EAAQP,gBAAA,CAAiBO,MAAA,EAAQ;MAC/BQ,QAAA,EAAUP,SAAA,KAAc;MACxBQ,YAAA,EAAc;QACZC,QAAA,eACErB,KAAA,CAAAsB,aAAA,CAACjB,aAAA;UAAckB,wBAAA,MAAwB;UAACZ,MAAA,EAAO;wBAC7CX,KAAA,CAAAsB,aAAA,CAAC;UACCE,IAAA,EAAK;UACLC,SAAA,EAAWX,cAAA,CAAeY,MAAM;UAChC;UACA,cAAW;wBAEX1B,KAAA,CAAAsB,aAAA,CAACnB,gBAAA;MAIT;IACF;EACF;AACF"}
@@ -1 +1 @@
1
- {"version":3,"names":["__styles","mergeClasses","shorthands","typographyStyles","TITLE_ACTION_GRID_AREA","TITLE_GRID_AREA","createFocusOutlineStyle","dialogTitleClassNames","root","action","useStyles","Bahqtrf","Be2twd7","Bhrd7zp","Bg96gwp","Ijaq50","Br312pm","nk6f5a","Bw0ie65","rootWithoutCloseButton","d","useDialogTitleInternalStyles","button","qhf8xq","B7ck84d","De3pzq","sj55zd","Bceei9c","B68tc82","Bmxbyg5","z8tnut","z189sj","Byoj8tv","uwmqm3","icvyot","vrafjx","oivjwe","wvpqe5","Bv0vk6g","fsow6f","Brovlpu","B486eqv","B8q5s1w","Bci5o5g","n8qw10","Bdrgwmp","Bm4h7ae","B7ys5i9","Busjfv9","Bhk32uz","Bf4ptjt","kclons","Bhdgwq3","Blkhhs4","Bqtpl0w","clg4pj","hgwjuy","Bonggc9","B1tsrr9","Dah5zi","Bkh64rk","qqdqy8","B6dhp37","i03rao","Boxcth7","Bsom6fd","J0r882","Bjwuhne","Ghsupd","Bule8hv","f","i","useDialogTitleStyles_unstable","state","styles","className"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogTitle/useDialogTitleStyles.ts"],"sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport type { DialogTitleSlots, DialogTitleState } from './DialogTitle.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\nimport { typographyStyles } from '@fluentui/react-theme';\nimport { TITLE_ACTION_GRID_AREA, TITLE_GRID_AREA } from '../../contexts/constants';\nimport { createFocusOutlineStyle } from '@fluentui/react-tabster';\n\nexport const dialogTitleClassNames: SlotClassNames<DialogTitleSlots> = {\n root: 'fui-DialogTitle',\n action: 'fui-DialogTitle__action',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n ...typographyStyles.subtitle1,\n ...shorthands.gridArea(TITLE_GRID_AREA),\n },\n rootWithoutCloseButton: {\n ...shorthands.gridArea(TITLE_GRID_AREA, TITLE_GRID_AREA, TITLE_ACTION_GRID_AREA, TITLE_ACTION_GRID_AREA),\n },\n action: {\n ...shorthands.gridArea(TITLE_ACTION_GRID_AREA),\n },\n});\n\n/**\n * Styles to be applied on internal elements used by default action on non-modal Dialog\n * @internal\n */\nexport const useDialogTitleInternalStyles = makeStyles({\n button: {\n position: 'relative',\n boxSizing: 'content-box',\n backgroundColor: 'inherit',\n color: 'inherit',\n fontFamily: 'inherit',\n fontSize: 'inherit',\n cursor: 'pointer',\n lineHeight: 0,\n ...shorthands.overflow('visible'),\n ...shorthands.padding(0),\n ...shorthands.borderStyle('none'),\n WebkitAppearance: 'button',\n textAlign: 'unset',\n ...createFocusOutlineStyle(),\n },\n});\n\n/**\n * Apply styling to the DialogTitle slots based on the state\n */\nexport const useDialogTitleStyles_unstable = (state: DialogTitleState): DialogTitleState => {\n const styles = useStyles();\n state.root.className = mergeClasses(\n dialogTitleClassNames.root,\n styles.root,\n !state.action && styles.rootWithoutCloseButton,\n state.root.className,\n );\n if (state.action) {\n state.action.className = mergeClasses(dialogTitleClassNames.action, styles.action, state.action.className);\n }\n return state;\n};\n"],"mappings":"AAAA,SAAAA,QAAA,EAAqBC,YAAY,EAAEC,UAAU,QAAQ,gBAAgB;AAGrE,SAASC,gBAAgB,QAAQ,uBAAuB;AACxD,SAASC,sBAAsB,EAAEC,eAAe,QAAQ,0BAA0B;AAClF,SAASC,uBAAuB,QAAQ,yBAAyB;AAEjE,OAAO,MAAMC,qBAAqB,GAAqC;EACrEC,IAAI,EAAE,iBAAiB;EACvBC,MAAM,EAAE;CACT;AAED;;;AAGA,MAAMC,SAAS,gBAAGV,QAAA;EAAAQ,IAAA;IAAAG,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;EAAAC,sBAAA;IAAAJ,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;EAAAT,MAAA;IAAAM,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;AAAA;EAAAE,CAAA;AAAA,EAWhB;AAEF;;;;AAIA,OAAO,MAAMC,4BAA4B,gBAAGrB,QAAA;EAAAsB,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAf,OAAA;IAAAC,OAAA;IAAAe,OAAA;IAAAb,OAAA;IAAAc,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;AAAA;EAAAjD,CAAA;EAAAkD,CAAA;EAAAC,CAAA;AAAA,EAiB1C;AAEF;;;AAGA,OAAO,MAAMC,6BAA6B,GAAIC,KAAuB,IAAsB;EACzF,MAAMC,MAAM,GAAGhE,SAAS,EAAE;EAC1B+D,KAAK,CAACjE,IAAI,CAACmE,SAAS,GAAG1E,YAAY,CACjCM,qBAAqB,CAACC,IAAI,EAC1BkE,MAAM,CAAClE,IAAI,EACX,CAACiE,KAAK,CAAChE,MAAM,IAAIiE,MAAM,CAACvD,sBAAsB,EAC9CsD,KAAK,CAACjE,IAAI,CAACmE,SAAS,CACrB;EACD,IAAIF,KAAK,CAAChE,MAAM,EAAE;IAChBgE,KAAK,CAAChE,MAAM,CAACkE,SAAS,GAAG1E,YAAY,CAACM,qBAAqB,CAACE,MAAM,EAAEiE,MAAM,CAACjE,MAAM,EAAEgE,KAAK,CAAChE,MAAM,CAACkE,SAAS,CAAC;;EAE5G,OAAOF,KAAK;AACd,CAAC"}
1
+ {"version":3,"names":["__styles","mergeClasses","shorthands","typographyStyles","TITLE_ACTION_GRID_AREA","TITLE_GRID_AREA","createFocusOutlineStyle","dialogTitleClassNames","root","action","useStyles","Bahqtrf","Be2twd7","Bhrd7zp","Bg96gwp","Ijaq50","Br312pm","nk6f5a","Bw0ie65","rootWithoutCloseButton","d","useDialogTitleInternalStyles","button","qhf8xq","B7ck84d","De3pzq","sj55zd","Bceei9c","B68tc82","Bmxbyg5","z8tnut","z189sj","Byoj8tv","uwmqm3","icvyot","vrafjx","oivjwe","wvpqe5","Bv0vk6g","fsow6f","Brovlpu","B486eqv","B8q5s1w","Bci5o5g","n8qw10","Bdrgwmp","Bm4h7ae","B7ys5i9","Busjfv9","Bhk32uz","Bf4ptjt","kclons","Bhdgwq3","Blkhhs4","Bqtpl0w","clg4pj","hgwjuy","Bonggc9","B1tsrr9","Dah5zi","Bkh64rk","qqdqy8","B6dhp37","i03rao","Boxcth7","Bsom6fd","J0r882","Bjwuhne","Ghsupd","Bule8hv","f","i","useDialogTitleStyles_unstable","state","styles","className"],"sources":["../../../src/components/DialogTitle/useDialogTitleStyles.ts"],"sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport type { DialogTitleSlots, DialogTitleState } from './DialogTitle.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\nimport { typographyStyles } from '@fluentui/react-theme';\nimport { TITLE_ACTION_GRID_AREA, TITLE_GRID_AREA } from '../../contexts/constants';\nimport { createFocusOutlineStyle } from '@fluentui/react-tabster';\n\nexport const dialogTitleClassNames: SlotClassNames<DialogTitleSlots> = {\n root: 'fui-DialogTitle',\n action: 'fui-DialogTitle__action',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n ...typographyStyles.subtitle1,\n ...shorthands.gridArea(TITLE_GRID_AREA),\n },\n rootWithoutCloseButton: {\n ...shorthands.gridArea(TITLE_GRID_AREA, TITLE_GRID_AREA, TITLE_ACTION_GRID_AREA, TITLE_ACTION_GRID_AREA),\n },\n action: {\n ...shorthands.gridArea(TITLE_ACTION_GRID_AREA),\n },\n});\n\n/**\n * Styles to be applied on internal elements used by default action on non-modal Dialog\n * @internal\n */\nexport const useDialogTitleInternalStyles = makeStyles({\n button: {\n position: 'relative',\n boxSizing: 'content-box',\n backgroundColor: 'inherit',\n color: 'inherit',\n fontFamily: 'inherit',\n fontSize: 'inherit',\n cursor: 'pointer',\n lineHeight: 0,\n ...shorthands.overflow('visible'),\n ...shorthands.padding(0),\n ...shorthands.borderStyle('none'),\n WebkitAppearance: 'button',\n textAlign: 'unset',\n ...createFocusOutlineStyle(),\n },\n});\n\n/**\n * Apply styling to the DialogTitle slots based on the state\n */\nexport const useDialogTitleStyles_unstable = (state: DialogTitleState): DialogTitleState => {\n const styles = useStyles();\n state.root.className = mergeClasses(\n dialogTitleClassNames.root,\n styles.root,\n !state.action && styles.rootWithoutCloseButton,\n state.root.className,\n );\n if (state.action) {\n state.action.className = mergeClasses(dialogTitleClassNames.action, styles.action, state.action.className);\n }\n return state;\n};\n"],"mappings":"AAAA,SAAAA,QAAA,EAAqBC,YAAY,EAAEC,UAAU,QAAQ;AAGrD,SAASC,gBAAgB,QAAQ;AACjC,SAASC,sBAAsB,EAAEC,eAAe,QAAQ;AACxD,SAASC,uBAAuB,QAAQ;AAExC,OAAO,MAAMC,qBAAA,GAA0D;EACrEC,IAAA,EAAM;EACNC,MAAA,EAAQ;AACV;AAEA;;;AAGA,MAAMC,SAAA,gBAAYV,QAAA;EAAAQ,IAAA;IAAAG,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;EAAAC,sBAAA;IAAAJ,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;EAAAT,MAAA;IAAAM,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;AAAA;EAAAE,CAAA;AAAA,EAWlB;AAEA;;;;AAIA,OAAO,MAAMC,4BAAA,gBAA+BrB,QAAA;EAAAsB,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAf,OAAA;IAAAC,OAAA;IAAAe,OAAA;IAAAb,OAAA;IAAAc,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;AAAA;EAAAjD,CAAA;EAAAkD,CAAA;EAAAC,CAAA;AAAA,EAiB5C;AAEA;;;AAGA,OAAO,MAAMC,6BAAA,GAAiCC,KAAA,IAA8C;EAC1F,MAAMC,MAAA,GAAShE,SAAA;EACf+D,KAAA,CAAMjE,IAAI,CAACmE,SAAS,GAAG1E,YAAA,CACrBM,qBAAA,CAAsBC,IAAI,EAC1BkE,MAAA,CAAOlE,IAAI,EACX,CAACiE,KAAA,CAAMhE,MAAM,IAAIiE,MAAA,CAAOvD,sBAAsB,EAC9CsD,KAAA,CAAMjE,IAAI,CAACmE,SAAS;EAEtB,IAAIF,KAAA,CAAMhE,MAAM,EAAE;IAChBgE,KAAA,CAAMhE,MAAM,CAACkE,SAAS,GAAG1E,YAAA,CAAaM,qBAAA,CAAsBE,MAAM,EAAEiE,MAAA,CAAOjE,MAAM,EAAEgE,KAAA,CAAMhE,MAAM,CAACkE,SAAS;EAC3G;EACA,OAAOF,KAAA;AACT"}
@@ -1,3 +1,4 @@
1
+ import * as React from 'react';
1
2
  import { useDialogTrigger_unstable } from './useDialogTrigger';
2
3
  import { renderDialogTrigger_unstable } from './renderDialogTrigger';
3
4
  /**
@@ -1 +1 @@
1
- {"version":3,"names":["useDialogTrigger_unstable","renderDialogTrigger_unstable","DialogTrigger","props","state","displayName","isFluentTriggerComponent"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogTrigger/DialogTrigger.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useDialogTrigger_unstable } from './useDialogTrigger';\nimport { renderDialogTrigger_unstable } from './renderDialogTrigger';\nimport type { DialogTriggerProps } from './DialogTrigger.types';\nimport type { FluentTriggerComponent } from '@fluentui/react-utilities';\n\n/**\n * A non-visual component that wraps its child\n * and configures them to be the trigger that will open or close a `Dialog`.\n * This component should only accept one child.\n *\n * In case the trigger is used outside `Dialog` component\n * it'll still provide basic ARIA related attributes\n * to it's wrapped child, but it won't be able to alter the dialog `open` state anymore,\n * in that case the user must provide a `controlled state`\n */\nexport const DialogTrigger: React.FC<DialogTriggerProps> = props => {\n const state = useDialogTrigger_unstable(props);\n\n return renderDialogTrigger_unstable(state);\n};\n\nDialogTrigger.displayName = 'DialogTrigger';\n// type casting here is required to ensure internal type FluentTriggerComponent is not leaked\n(DialogTrigger as FluentTriggerComponent).isFluentTriggerComponent = true;\n"],"mappings":"AACA,SAASA,yBAAyB,QAAQ,oBAAoB;AAC9D,SAASC,4BAA4B,QAAQ,uBAAuB;AAIpE;;;;;;;;;;AAUA,OAAO,MAAMC,aAAa,GAAiCC,KAAK,IAAG;EACjE,MAAMC,KAAK,GAAGJ,yBAAyB,CAACG,KAAK,CAAC;EAE9C,OAAOF,4BAA4B,CAACG,KAAK,CAAC;AAC5C,CAAC;AAEDF,aAAa,CAACG,WAAW,GAAG,eAAe;AAC3C;AACCH,aAAwC,CAACI,wBAAwB,GAAG,IAAI"}
1
+ {"version":3,"names":["React","useDialogTrigger_unstable","renderDialogTrigger_unstable","DialogTrigger","props","state","displayName","isFluentTriggerComponent"],"sources":["../../../src/components/DialogTrigger/DialogTrigger.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useDialogTrigger_unstable } from './useDialogTrigger';\nimport { renderDialogTrigger_unstable } from './renderDialogTrigger';\nimport type { DialogTriggerProps } from './DialogTrigger.types';\nimport type { FluentTriggerComponent } from '@fluentui/react-utilities';\n\n/**\n * A non-visual component that wraps its child\n * and configures them to be the trigger that will open or close a `Dialog`.\n * This component should only accept one child.\n *\n * In case the trigger is used outside `Dialog` component\n * it'll still provide basic ARIA related attributes\n * to it's wrapped child, but it won't be able to alter the dialog `open` state anymore,\n * in that case the user must provide a `controlled state`\n */\nexport const DialogTrigger: React.FC<DialogTriggerProps> = props => {\n const state = useDialogTrigger_unstable(props);\n\n return renderDialogTrigger_unstable(state);\n};\n\nDialogTrigger.displayName = 'DialogTrigger';\n// type casting here is required to ensure internal type FluentTriggerComponent is not leaked\n(DialogTrigger as FluentTriggerComponent).isFluentTriggerComponent = true;\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SAASC,yBAAyB,QAAQ;AAC1C,SAASC,4BAA4B,QAAQ;AAI7C;;;;;;;;;;AAUA,OAAO,MAAMC,aAAA,GAA8CC,KAAA,IAAS;EAClE,MAAMC,KAAA,GAAQJ,yBAAA,CAA0BG,KAAA;EAExC,OAAOF,4BAAA,CAA6BG,KAAA;AACtC;AAEAF,aAAA,CAAcG,WAAW,GAAG;AAC5B;AACCH,aAAA,CAAyCI,wBAAwB,GAAG,IAAI"}
@@ -1,2 +1,2 @@
1
- export {};
1
+ import * as React from 'react';
2
2
  //# sourceMappingURL=DialogTrigger.types.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"DialogTrigger.types.js","sourceRoot":"../src/","sources":["packages/react-components/react-dialog/src/components/DialogTrigger/DialogTrigger.types.ts"],"names":[],"mappings":"","sourcesContent":["import { ARIAButtonResultProps, ARIAButtonType } from '@fluentui/react-aria';\nimport type { TriggerProps } from '@fluentui/react-utilities';\nimport * as React from 'react';\n\nexport type DialogTriggerAction = 'open' | 'close';\n\nexport type DialogTriggerProps = TriggerProps<DialogTriggerChildProps> & {\n /**\n * Explicitly declare if the trigger is responsible for opening or\n * closing a Dialog visibility state.\n *\n * If `DialogTrigger` is outside `DialogSurface` then it'll be `open` by default\n *\n * If `DialogTrigger` is inside `DialogSurface` then it'll be `close` by default\n */\n action?: DialogTriggerAction;\n /**\n * Disables internal trigger mechanism that ensures a child provided will be a compliant ARIA button.\n * @default false\n */\n disableButtonEnhancement?: boolean;\n};\n\n/**\n * Props that are passed to the child of the DialogTrigger when cloned to ensure correct behaviour for the Dialog\n */\nexport type DialogTriggerChildProps<Type extends ARIAButtonType = ARIAButtonType, Props = {}> = ARIAButtonResultProps<\n Type,\n Props & {\n 'aria-haspopup'?: 'dialog';\n }\n>;\n\nexport type DialogTriggerState = {\n children: React.ReactElement | null;\n};\n"]}
1
+ {"version":3,"names":["React"],"sources":["../../../src/components/DialogTrigger/DialogTrigger.types.ts"],"sourcesContent":["import { ARIAButtonResultProps, ARIAButtonType } from '@fluentui/react-aria';\nimport type { TriggerProps } from '@fluentui/react-utilities';\nimport * as React from 'react';\n\nexport type DialogTriggerAction = 'open' | 'close';\n\nexport type DialogTriggerProps = TriggerProps<DialogTriggerChildProps> & {\n /**\n * Explicitly declare if the trigger is responsible for opening or\n * closing a Dialog visibility state.\n *\n * If `DialogTrigger` is outside `DialogSurface` then it'll be `open` by default\n *\n * If `DialogTrigger` is inside `DialogSurface` then it'll be `close` by default\n */\n action?: DialogTriggerAction;\n /**\n * Disables internal trigger mechanism that ensures a child provided will be a compliant ARIA button.\n * @default false\n */\n disableButtonEnhancement?: boolean;\n};\n\n/**\n * Props that are passed to the child of the DialogTrigger when cloned to ensure correct behaviour for the Dialog\n */\nexport type DialogTriggerChildProps<Type extends ARIAButtonType = ARIAButtonType, Props = {}> = ARIAButtonResultProps<\n Type,\n Props & {\n 'aria-haspopup'?: 'dialog';\n }\n>;\n\nexport type DialogTriggerState = {\n children: React.ReactElement | null;\n};\n"],"mappings":"AAEA,YAAYA,KAAA,MAAW"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["packages/react-components/react-dialog/src/components/DialogTrigger/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,uBAAuB,CAAC;AACtC,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC","sourcesContent":["export * from './DialogTrigger';\nexport * from './DialogTrigger.types';\nexport * from './renderDialogTrigger';\nexport * from './useDialogTrigger';\n"]}
1
+ {"version":3,"names":[],"sources":["../../../src/components/DialogTrigger/index.ts"],"sourcesContent":["export * from './DialogTrigger';\nexport * from './DialogTrigger.types';\nexport * from './renderDialogTrigger';\nexport * from './useDialogTrigger';\n"],"mappings":"AAAA,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc"}
@@ -2,6 +2,5 @@
2
2
  * Render the final JSX of MenuTrigger
3
3
  *
4
4
  * Only renders children
5
- */
6
- export const renderDialogTrigger_unstable = state => state.children;
5
+ */export const renderDialogTrigger_unstable = state => state.children;
7
6
  //# sourceMappingURL=renderDialogTrigger.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["renderDialogTrigger_unstable","state","children"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogTrigger/renderDialogTrigger.tsx"],"sourcesContent":["import type { DialogTriggerState } from './DialogTrigger.types';\n\n/**\n * Render the final JSX of MenuTrigger\n *\n * Only renders children\n */\nexport const renderDialogTrigger_unstable = (state: DialogTriggerState) => state.children;\n"],"mappings":"AAEA;;;;;AAKA,OAAO,MAAMA,4BAA4B,GAAIC,KAAyB,IAAKA,KAAK,CAACC,QAAQ"}
1
+ {"version":3,"names":["renderDialogTrigger_unstable","state","children"],"sources":["../../../src/components/DialogTrigger/renderDialogTrigger.tsx"],"sourcesContent":["import type { DialogTriggerState } from './DialogTrigger.types';\n\n/**\n * Render the final JSX of MenuTrigger\n *\n * Only renders children\n */\nexport const renderDialogTrigger_unstable = (state: DialogTriggerState) => state.children;\n"],"mappings":"AAEA;;;;GAKA,OAAO,MAAMA,4BAAA,GAAgCC,KAAA,IAA8BA,KAAA,CAAMC,QAAQ"}
@@ -1,3 +1,4 @@
1
+ import * as React from 'react';
1
2
  import { useModalAttributes } from '@fluentui/react-tabster';
2
3
  import { applyTriggerPropsToChildren, getTriggerChild, useEventCallback } from '@fluentui/react-utilities';
3
4
  import { useDialogContext_unstable, useDialogSurfaceContext_unstable } from '../../contexts';
@@ -22,8 +23,8 @@ export const useDialogTrigger_unstable = props => {
22
23
  triggerAttributes
23
24
  } = useModalAttributes();
24
25
  const handleClick = useEventCallback(event => {
25
- var _a, _b;
26
- (_b = child === null || child === void 0 ? void 0 : (_a = child.props).onClick) === null || _b === void 0 ? void 0 : _b.call(_a, event);
26
+ var _child_props, _child_props_onClick;
27
+ (_child_props_onClick = (_child_props = child === null || child === void 0 ? void 0 : child.props).onClick) === null || _child_props_onClick === void 0 ? void 0 : _child_props_onClick.call(_child_props, event);
27
28
  if (!event.isDefaultPrevented()) {
28
29
  requestOpenChange({
29
30
  event,
@@ -1 +1 @@
1
- {"version":3,"names":["useModalAttributes","applyTriggerPropsToChildren","getTriggerChild","useEventCallback","useDialogContext_unstable","useDialogSurfaceContext_unstable","useARIAButtonProps","useDialogTrigger_unstable","props","isInsideSurfaceDialog","children","disableButtonEnhancement","action","child","requestOpenChange","ctx","open","triggerAttributes","handleClick","event","_b","_a","onClick","call","isDefaultPrevented","type","triggerChildProps","ref","ariaButtonTriggerChildProps"],"sources":["../src/packages/react-components/react-dialog/src/components/DialogTrigger/useDialogTrigger.ts"],"sourcesContent":["import * as React from 'react';\nimport { useModalAttributes } from '@fluentui/react-tabster';\nimport { applyTriggerPropsToChildren, getTriggerChild, useEventCallback } from '@fluentui/react-utilities';\nimport type { DialogTriggerProps, DialogTriggerState } from './DialogTrigger.types';\nimport { useDialogContext_unstable, useDialogSurfaceContext_unstable } from '../../contexts';\nimport { useARIAButtonProps } from '@fluentui/react-aria';\n\n/**\n * Create the state required to render DialogTrigger.\n * Clones the only child component and adds necessary event handling behaviours to open a popup Dialog\n *\n * @param props - props from this instance of DialogTrigger\n */\nexport const useDialogTrigger_unstable = (props: DialogTriggerProps): DialogTriggerState => {\n const isInsideSurfaceDialog = useDialogSurfaceContext_unstable();\n\n const { children, disableButtonEnhancement = false, action = isInsideSurfaceDialog ? 'close' : 'open' } = props;\n\n const child = getTriggerChild(children);\n\n const requestOpenChange = useDialogContext_unstable(ctx => ctx.requestOpenChange);\n const open = useDialogContext_unstable(ctx => ctx.open);\n\n const { triggerAttributes } = useModalAttributes();\n\n const handleClick = useEventCallback(\n (event: React.MouseEvent<HTMLButtonElement & HTMLAnchorElement & HTMLDivElement>) => {\n child?.props.onClick?.(event);\n if (!event.isDefaultPrevented()) {\n requestOpenChange({\n event,\n type: 'triggerClick',\n open: action === 'open',\n });\n }\n },\n );\n\n const triggerChildProps = {\n ...child?.props,\n 'aria-expanded': open,\n ref: child?.ref,\n onClick: handleClick,\n ...triggerAttributes,\n } as const;\n\n const ariaButtonTriggerChildProps = useARIAButtonProps(\n child?.type === 'button' || child?.type === 'a' ? child.type : 'div',\n {\n ...triggerChildProps,\n type: 'button',\n },\n );\n\n return {\n children: applyTriggerPropsToChildren(\n children,\n disableButtonEnhancement ? triggerChildProps : ariaButtonTriggerChildProps,\n ),\n };\n};\n"],"mappings":"AACA,SAASA,kBAAkB,QAAQ,yBAAyB;AAC5D,SAASC,2BAA2B,EAAEC,eAAe,EAAEC,gBAAgB,QAAQ,2BAA2B;AAE1G,SAASC,yBAAyB,EAAEC,gCAAgC,QAAQ,gBAAgB;AAC5F,SAASC,kBAAkB,QAAQ,sBAAsB;AAEzD;;;;;;AAMA,OAAO,MAAMC,yBAAyB,GAAIC,KAAyB,IAAwB;EACzF,MAAMC,qBAAqB,GAAGJ,gCAAgC,EAAE;EAEhE,MAAM;IAAEK,QAAQ;IAAEC,wBAAwB,GAAG,KAAK;IAAEC,MAAM,GAAGH,qBAAqB,GAAG,OAAO,GAAG;EAAM,CAAE,GAAGD,KAAK;EAE/G,MAAMK,KAAK,GAAGX,eAAe,CAACQ,QAAQ,CAAC;EAEvC,MAAMI,iBAAiB,GAAGV,yBAAyB,CAACW,GAAG,IAAIA,GAAG,CAACD,iBAAiB,CAAC;EACjF,MAAME,IAAI,GAAGZ,yBAAyB,CAACW,GAAG,IAAIA,GAAG,CAACC,IAAI,CAAC;EAEvD,MAAM;IAAEC;EAAiB,CAAE,GAAGjB,kBAAkB,EAAE;EAElD,MAAMkB,WAAW,GAAGf,gBAAgB,CACjCgB,KAA+E,IAAI;;IAClF,CAAAC,EAAA,GAAAP,KAAK,aAALA,KAAK,wBAAAQ,EAAA,GAALR,KAAK,CAAEL,KAAK,EAACc,OAAO,cAAAF,EAAA,uBAAAA,EAAA,CAAAG,IAAA,CAAAF,EAAA,EAAGF,KAAK,CAAC;IAC7B,IAAI,CAACA,KAAK,CAACK,kBAAkB,EAAE,EAAE;MAC/BV,iBAAiB,CAAC;QAChBK,KAAK;QACLM,IAAI,EAAE,cAAc;QACpBT,IAAI,EAAEJ,MAAM,KAAK;OAClB,CAAC;;EAEN,CAAC,CACF;EAED,MAAMc,iBAAiB,GAAG;IACxB,IAAGb,KAAK,aAALA,KAAK,uBAALA,KAAK,CAAEL,KAAK;IACf,eAAe,EAAEQ,IAAI;IACrBW,GAAG,EAAEd,KAAK,aAALA,KAAK,uBAALA,KAAK,CAAEc,GAAG;IACfL,OAAO,EAAEJ,WAAW;IACpB,GAAGD;GACK;EAEV,MAAMW,2BAA2B,GAAGtB,kBAAkB,CACpD,CAAAO,KAAK,aAALA,KAAK,uBAALA,KAAK,CAAEY,IAAI,MAAK,QAAQ,IAAI,CAAAZ,KAAK,aAALA,KAAK,uBAALA,KAAK,CAAEY,IAAI,MAAK,GAAG,GAAGZ,KAAK,CAACY,IAAI,GAAG,KAAK,EACpE;IACE,GAAGC,iBAAiB;IACpBD,IAAI,EAAE;GACP,CACF;EAED,OAAO;IACLf,QAAQ,EAAET,2BAA2B,CACnCS,QAAQ,EACRC,wBAAwB,GAAGe,iBAAiB,GAAGE,2BAA2B;GAE7E;AACH,CAAC"}
1
+ {"version":3,"names":["React","useModalAttributes","applyTriggerPropsToChildren","getTriggerChild","useEventCallback","useDialogContext_unstable","useDialogSurfaceContext_unstable","useARIAButtonProps","useDialogTrigger_unstable","props","isInsideSurfaceDialog","children","disableButtonEnhancement","action","child","requestOpenChange","ctx","open","triggerAttributes","handleClick","event","_child_props","_child_props_onClick","onClick","call","isDefaultPrevented","type","triggerChildProps","ref","ariaButtonTriggerChildProps"],"sources":["../../../src/components/DialogTrigger/useDialogTrigger.ts"],"sourcesContent":["import * as React from 'react';\nimport { useModalAttributes } from '@fluentui/react-tabster';\nimport { applyTriggerPropsToChildren, getTriggerChild, useEventCallback } from '@fluentui/react-utilities';\nimport type { DialogTriggerProps, DialogTriggerState } from './DialogTrigger.types';\nimport { useDialogContext_unstable, useDialogSurfaceContext_unstable } from '../../contexts';\nimport { useARIAButtonProps } from '@fluentui/react-aria';\n\n/**\n * Create the state required to render DialogTrigger.\n * Clones the only child component and adds necessary event handling behaviours to open a popup Dialog\n *\n * @param props - props from this instance of DialogTrigger\n */\nexport const useDialogTrigger_unstable = (props: DialogTriggerProps): DialogTriggerState => {\n const isInsideSurfaceDialog = useDialogSurfaceContext_unstable();\n\n const { children, disableButtonEnhancement = false, action = isInsideSurfaceDialog ? 'close' : 'open' } = props;\n\n const child = getTriggerChild(children);\n\n const requestOpenChange = useDialogContext_unstable(ctx => ctx.requestOpenChange);\n const open = useDialogContext_unstable(ctx => ctx.open);\n\n const { triggerAttributes } = useModalAttributes();\n\n const handleClick = useEventCallback(\n (event: React.MouseEvent<HTMLButtonElement & HTMLAnchorElement & HTMLDivElement>) => {\n child?.props.onClick?.(event);\n if (!event.isDefaultPrevented()) {\n requestOpenChange({\n event,\n type: 'triggerClick',\n open: action === 'open',\n });\n }\n },\n );\n\n const triggerChildProps = {\n ...child?.props,\n 'aria-expanded': open,\n ref: child?.ref,\n onClick: handleClick,\n ...triggerAttributes,\n } as const;\n\n const ariaButtonTriggerChildProps = useARIAButtonProps(\n child?.type === 'button' || child?.type === 'a' ? child.type : 'div',\n {\n ...triggerChildProps,\n type: 'button',\n },\n );\n\n return {\n children: applyTriggerPropsToChildren(\n children,\n disableButtonEnhancement ? triggerChildProps : ariaButtonTriggerChildProps,\n ),\n };\n};\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SAASC,kBAAkB,QAAQ;AACnC,SAASC,2BAA2B,EAAEC,eAAe,EAAEC,gBAAgB,QAAQ;AAE/E,SAASC,yBAAyB,EAAEC,gCAAgC,QAAQ;AAC5E,SAASC,kBAAkB,QAAQ;AAEnC;;;;;;AAMA,OAAO,MAAMC,yBAAA,GAA6BC,KAAA,IAAkD;EAC1F,MAAMC,qBAAA,GAAwBJ,gCAAA;EAE9B,MAAM;IAAEK,QAAA;IAAUC,wBAAA,GAA2B,KAAK;IAAEC,MAAA,GAASH,qBAAA,GAAwB,UAAU;EAAM,CAAE,GAAGD,KAAA;EAE1G,MAAMK,KAAA,GAAQX,eAAA,CAAgBQ,QAAA;EAE9B,MAAMI,iBAAA,GAAoBV,yBAAA,CAA0BW,GAAA,IAAOA,GAAA,CAAID,iBAAiB;EAChF,MAAME,IAAA,GAAOZ,yBAAA,CAA0BW,GAAA,IAAOA,GAAA,CAAIC,IAAI;EAEtD,MAAM;IAAEC;EAAiB,CAAE,GAAGjB,kBAAA;EAE9B,MAAMkB,WAAA,GAAcf,gBAAA,CACjBgB,KAAA,IAAoF;QACnFC,YAAA,EAAAC,oBAAA;IAAA,CAAAA,oBAAA,IAAAD,YAAA,GAAAP,KAAA,aAAAA,KAAA,uBAAAA,KAAA,CAAOL,KAAK,EAACc,OAAO,cAApBD,oBAAA,uBAAAA,oBAAA,CAAAE,IAAA,CAAAH,YAAA,EAAuBD,KAAA;IACvB,IAAI,CAACA,KAAA,CAAMK,kBAAkB,IAAI;MAC/BV,iBAAA,CAAkB;QAChBK,KAAA;QACAM,IAAA,EAAM;QACNT,IAAA,EAAMJ,MAAA,KAAW;MACnB;IACF;EACF;EAGF,MAAMc,iBAAA,GAAoB;IACxB,IAAGb,KAAA,aAAAA,KAAA,uBAAAA,KAAA,CAAOL,KAAK;IACf,iBAAiBQ,IAAA;IACjBW,GAAA,EAAKd,KAAA,aAAAA,KAAA,uBAAAA,KAAA,CAAOc,GAAG;IACfL,OAAA,EAASJ,WAAA;IACT,GAAGD;EACL;EAEA,MAAMW,2BAAA,GAA8BtB,kBAAA,CAClC,CAAAO,KAAA,aAAAA,KAAA,uBAAAA,KAAA,CAAOY,IAAI,MAAK,YAAY,CAAAZ,KAAA,aAAAA,KAAA,uBAAAA,KAAA,CAAOY,IAAI,MAAK,MAAMZ,KAAA,CAAMY,IAAI,GAAG,KAAK,EACpE;IACE,GAAGC,iBAAiB;IACpBD,IAAA,EAAM;EACR;EAGF,OAAO;IACLf,QAAA,EAAUT,2BAAA,CACRS,QAAA,EACAC,wBAAA,GAA2Be,iBAAA,GAAoBE,2BAA2B;EAE9E;AACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"../src/","sources":["packages/react-components/react-dialog/src/contexts/constants.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,+BAA+B,GAAG,sCAAsC,CAAC;AACtF,MAAM,CAAC,MAAM,eAAe,GAAG,MAAM,CAAC;AACtC,MAAM,CAAC,MAAM,UAAU,GAAG,KAAK,CAAC;AAChC,MAAM,CAAC,MAAM,oBAAoB,GAAG,KAAK,CAAC;AAE1C,MAAM,CAAC,MAAM,uBAAuB,GAAG,eAAe,CAAC;AACvD,MAAM,CAAC,MAAM,qBAAqB,GAAG,aAAa,CAAC;AACnD,MAAM,CAAC,MAAM,eAAe,GAAG,OAAO,CAAC;AACvC,MAAM,CAAC,MAAM,sBAAsB,GAAG,cAAc,CAAC;AACrD,MAAM,CAAC,MAAM,iBAAiB,GAAG,MAAM,CAAC","sourcesContent":["export const MEDIA_QUERY_BREAKPOINT_SELECTOR = '@media screen and (max-width: 480px)';\nexport const SURFACE_PADDING = '24px';\nexport const DIALOG_GAP = '8px';\nexport const SURFACE_BORDER_WIDTH = '1px';\n\nexport const ACTIONS_START_GRID_AREA = 'actions-start';\nexport const ACTIONS_END_GRID_AREA = 'actions-end';\nexport const TITLE_GRID_AREA = 'title';\nexport const TITLE_ACTION_GRID_AREA = 'close-button';\nexport const CONTENT_GRID_AREA = 'body';\n"]}
1
+ {"version":3,"names":["MEDIA_QUERY_BREAKPOINT_SELECTOR","SURFACE_PADDING","DIALOG_GAP","SURFACE_BORDER_WIDTH","ACTIONS_START_GRID_AREA","ACTIONS_END_GRID_AREA","TITLE_GRID_AREA","TITLE_ACTION_GRID_AREA","CONTENT_GRID_AREA"],"sources":["../../src/contexts/constants.ts"],"sourcesContent":["export const MEDIA_QUERY_BREAKPOINT_SELECTOR = '@media screen and (max-width: 480px)';\nexport const SURFACE_PADDING = '24px';\nexport const DIALOG_GAP = '8px';\nexport const SURFACE_BORDER_WIDTH = '1px';\n\nexport const ACTIONS_START_GRID_AREA = 'actions-start';\nexport const ACTIONS_END_GRID_AREA = 'actions-end';\nexport const TITLE_GRID_AREA = 'title';\nexport const TITLE_ACTION_GRID_AREA = 'close-button';\nexport const CONTENT_GRID_AREA = 'body';\n"],"mappings":"AAAA,OAAO,MAAMA,+BAAA,GAAkC;AAC/C,OAAO,MAAMC,eAAA,GAAkB;AAC/B,OAAO,MAAMC,UAAA,GAAa;AAC1B,OAAO,MAAMC,oBAAA,GAAuB;AAEpC,OAAO,MAAMC,uBAAA,GAA0B;AACvC,OAAO,MAAMC,qBAAA,GAAwB;AACrC,OAAO,MAAMC,eAAA,GAAkB;AAC/B,OAAO,MAAMC,sBAAA,GAAyB;AACtC,OAAO,MAAMC,iBAAA,GAAoB"}
@@ -1,3 +1,4 @@
1
+ import * as React from 'react';
1
2
  import { createContext, useContextSelector } from '@fluentui/react-context-selector';
2
3
  const defaultContextValue = {
3
4
  open: false,
@@ -8,8 +9,7 @@ const defaultContextValue = {
8
9
  current: null
9
10
  },
10
11
  requestOpenChange() {
11
- /* noop */
12
- }
12
+ /* noop */}
13
13
  };
14
14
  // Contexts should default to undefined
15
15
  export const DialogContext = /*#__PURE__*/createContext(undefined);
@@ -1 +1 @@
1
- {"version":3,"names":["createContext","useContextSelector","defaultContextValue","open","inertTrapFocus","modalType","isNestedDialog","dialogRef","current","requestOpenChange","DialogContext","undefined","DialogProvider","Provider","useDialogContext_unstable","selector","ctx"],"sources":["../src/packages/react-components/react-dialog/src/contexts/dialogContext.ts"],"sourcesContent":["import * as React from 'react';\nimport { createContext, ContextSelector, useContextSelector } from '@fluentui/react-context-selector';\nimport { DialogSurfaceElement } from '../DialogSurface';\nimport type { Context } from '@fluentui/react-context-selector';\nimport type { DialogModalType, DialogOpenChangeData } from '../Dialog';\n\nexport type DialogContextValue = {\n open: boolean;\n inertTrapFocus: boolean;\n dialogTitleId?: string;\n isNestedDialog: boolean;\n dialogRef: React.Ref<DialogSurfaceElement>;\n modalType: DialogModalType;\n /**\n * Requests dialog main component to update it's internal open state\n */\n requestOpenChange: (data: DialogOpenChangeData) => void;\n};\n\nconst defaultContextValue: DialogContextValue = {\n open: false,\n inertTrapFocus: false,\n modalType: 'modal',\n isNestedDialog: false,\n dialogRef: { current: null },\n requestOpenChange() {\n /* noop */\n },\n};\n\n// Contexts should default to undefined\nexport const DialogContext: Context<DialogContextValue | undefined> = createContext<DialogContextValue | undefined>(\n undefined,\n);\n\nexport const DialogProvider = DialogContext.Provider;\nexport const useDialogContext_unstable = <T>(selector: ContextSelector<DialogContextValue, T>): T =>\n useContextSelector(DialogContext, (ctx = defaultContextValue) => selector(ctx));\n"],"mappings":"AACA,SAASA,aAAa,EAAmBC,kBAAkB,QAAQ,kCAAkC;AAkBrG,MAAMC,mBAAmB,GAAuB;EAC9CC,IAAI,EAAE,KAAK;EACXC,cAAc,EAAE,KAAK;EACrBC,SAAS,EAAE,OAAO;EAClBC,cAAc,EAAE,KAAK;EACrBC,SAAS,EAAE;IAAEC,OAAO,EAAE;EAAI,CAAE;EAC5BC,iBAAiBA,CAAA;IACf;EAAA;CAEH;AAED;AACA,OAAO,MAAMC,aAAa,gBAA4CV,aAAa,CACjFW,SAAS,CACV;AAED,OAAO,MAAMC,cAAc,GAAGF,aAAa,CAACG,QAAQ;AACpD,OAAO,MAAMC,yBAAyB,GAAOC,QAAgD,IAC3Fd,kBAAkB,CAACS,aAAa,EAAE,CAACM,GAAG,GAAGd,mBAAmB,KAAKa,QAAQ,CAACC,GAAG,CAAC,CAAC"}
1
+ {"version":3,"names":["React","createContext","useContextSelector","defaultContextValue","open","inertTrapFocus","modalType","isNestedDialog","dialogRef","current","requestOpenChange","DialogContext","undefined","DialogProvider","Provider","useDialogContext_unstable","selector","ctx"],"sources":["../../src/contexts/dialogContext.ts"],"sourcesContent":["import * as React from 'react';\nimport { createContext, ContextSelector, useContextSelector } from '@fluentui/react-context-selector';\nimport { DialogSurfaceElement } from '../DialogSurface';\nimport type { Context } from '@fluentui/react-context-selector';\nimport type { DialogModalType, DialogOpenChangeData } from '../Dialog';\n\nexport type DialogContextValue = {\n open: boolean;\n inertTrapFocus: boolean;\n dialogTitleId?: string;\n isNestedDialog: boolean;\n dialogRef: React.Ref<DialogSurfaceElement>;\n modalType: DialogModalType;\n /**\n * Requests dialog main component to update it's internal open state\n */\n requestOpenChange: (data: DialogOpenChangeData) => void;\n};\n\nconst defaultContextValue: DialogContextValue = {\n open: false,\n inertTrapFocus: false,\n modalType: 'modal',\n isNestedDialog: false,\n dialogRef: { current: null },\n requestOpenChange() {\n /* noop */\n },\n};\n\n// Contexts should default to undefined\nexport const DialogContext: Context<DialogContextValue | undefined> = createContext<DialogContextValue | undefined>(\n undefined,\n);\n\nexport const DialogProvider = DialogContext.Provider;\nexport const useDialogContext_unstable = <T>(selector: ContextSelector<DialogContextValue, T>): T =>\n useContextSelector(DialogContext, (ctx = defaultContextValue) => selector(ctx));\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SAASC,aAAa,EAAmBC,kBAAkB,QAAQ;AAkBnE,MAAMC,mBAAA,GAA0C;EAC9CC,IAAA,EAAM,KAAK;EACXC,cAAA,EAAgB,KAAK;EACrBC,SAAA,EAAW;EACXC,cAAA,EAAgB,KAAK;EACrBC,SAAA,EAAW;IAAEC,OAAA,EAAS;EAAK;EAC3BC,kBAAA,EAAoB;IAClB;AAEJ;AAEA;AACA,OAAO,MAAMC,aAAA,gBAAyDV,aAAA,CACpEW,SAAA;AAGF,OAAO,MAAMC,cAAA,GAAiBF,aAAA,CAAcG,QAAQ;AACpD,OAAO,MAAMC,yBAAA,GAAgCC,QAAA,IAC3Cd,kBAAA,CAAmBS,aAAA,EAAe,CAACM,GAAA,GAAMd,mBAAmB,KAAKa,QAAA,CAASC,GAAA"}
@@ -2,8 +2,6 @@ import { createContext, useContext } from 'react';
2
2
  const defaultContextValue = false;
3
3
  export const DialogSurfaceContext = /*#__PURE__*/createContext(undefined);
4
4
  export const DialogSurfaceProvider = DialogSurfaceContext.Provider;
5
- export const useDialogSurfaceContext_unstable = () => {
6
- var _a;
7
- return (_a = useContext(DialogSurfaceContext)) !== null && _a !== void 0 ? _a : defaultContextValue;
8
- };
5
+ var _useContext;
6
+ export const useDialogSurfaceContext_unstable = () => (_useContext = useContext(DialogSurfaceContext)) !== null && _useContext !== void 0 ? _useContext : defaultContextValue;
9
7
  //# sourceMappingURL=dialogSurfaceContext.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["createContext","useContext","defaultContextValue","DialogSurfaceContext","undefined","DialogSurfaceProvider","Provider","useDialogSurfaceContext_unstable","_a"],"sources":["../src/packages/react-components/react-dialog/src/contexts/dialogSurfaceContext.ts"],"sourcesContent":["import { createContext, useContext } from 'react';\n\nexport type DialogSurfaceContextValue = boolean;\n\nconst defaultContextValue: DialogSurfaceContextValue = false;\n\nexport const DialogSurfaceContext = createContext<DialogSurfaceContextValue | undefined>(undefined);\n\nexport const DialogSurfaceProvider = DialogSurfaceContext.Provider;\n\nexport const useDialogSurfaceContext_unstable = () => useContext(DialogSurfaceContext) ?? defaultContextValue;\n"],"mappings":"AAAA,SAASA,aAAa,EAAEC,UAAU,QAAQ,OAAO;AAIjD,MAAMC,mBAAmB,GAA8B,KAAK;AAE5D,OAAO,MAAMC,oBAAoB,gBAAGH,aAAa,CAAwCI,SAAS,CAAC;AAEnG,OAAO,MAAMC,qBAAqB,GAAGF,oBAAoB,CAACG,QAAQ;AAElE,OAAO,MAAMC,gCAAgC,GAAGA,CAAA,KAAK;EAAA,IAAAC,EAAA;EAAC,QAAAA,EAAA,GAAAP,UAAU,CAACE,oBAAoB,CAAC,cAAAK,EAAA,cAAAA,EAAA,GAAIN,mBAAmB;AAAA"}
1
+ {"version":3,"names":["createContext","useContext","defaultContextValue","DialogSurfaceContext","undefined","DialogSurfaceProvider","Provider","_useContext","useDialogSurfaceContext_unstable"],"sources":["../../src/contexts/dialogSurfaceContext.ts"],"sourcesContent":["import { createContext, useContext } from 'react';\n\nexport type DialogSurfaceContextValue = boolean;\n\nconst defaultContextValue: DialogSurfaceContextValue = false;\n\nexport const DialogSurfaceContext = createContext<DialogSurfaceContextValue | undefined>(undefined);\n\nexport const DialogSurfaceProvider = DialogSurfaceContext.Provider;\n\nexport const useDialogSurfaceContext_unstable = () => useContext(DialogSurfaceContext) ?? defaultContextValue;\n"],"mappings":"AAAA,SAASA,aAAa,EAAEC,UAAU,QAAQ;AAI1C,MAAMC,mBAAA,GAAiD,KAAK;AAE5D,OAAO,MAAMC,oBAAA,gBAAuBH,aAAA,CAAqDI,SAAA;AAEzF,OAAO,MAAMC,qBAAA,GAAwBF,oBAAA,CAAqBG,QAAQ;IAEZC,WAAA;AAAtD,OAAO,MAAMC,gCAAA,GAAmCA,CAAA,KAAM,CAAAD,WAAA,GAAAN,UAAA,CAAWE,oBAAA,eAAXI,WAAA,cAAAA,WAAA,GAAoCL,mBAAmB"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["packages/react-components/react-dialog/src/contexts/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,iBAAiB,CAAC;AAChC,cAAc,wBAAwB,CAAC","sourcesContent":["export * from './constants';\nexport * from './dialogContext';\nexport * from './dialogSurfaceContext';\n"]}
1
+ {"version":3,"names":[],"sources":["../../src/contexts/index.ts"],"sourcesContent":["export * from './constants';\nexport * from './dialogContext';\nexport * from './dialogSurfaceContext';\n"],"mappings":"AAAA,cAAc;AACd,cAAc;AACd,cAAc"}
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"names":["Dialog","renderDialog_unstable","useDialog_unstable","DialogTrigger","useDialogTrigger_unstable","renderDialogTrigger_unstable","DialogActions","dialogActionsClassNames","useDialogActions_unstable","useDialogActionsStyles_unstable","renderDialogActions_unstable","DialogBody","dialogBodyClassNames","useDialogBody_unstable","useDialogBodyStyles_unstable","renderDialogBody_unstable","DialogTitle","dialogTitleClassNames","useDialogTitle_unstable","useDialogTitleStyles_unstable","renderDialogTitle_unstable","DialogSurface","dialogSurfaceClassNames","useDialogSurface_unstable","useDialogSurfaceStyles_unstable","renderDialogSurface_unstable","DialogContent","dialogContentClassNames","useDialogContent_unstable","useDialogContentStyles_unstable","renderDialogContent_unstable"],"sources":["../src/packages/react-components/react-dialog/src/index.ts"],"sourcesContent":["export { Dialog, renderDialog_unstable, useDialog_unstable } from './Dialog';\nexport type {\n DialogSlots,\n DialogProps,\n DialogState,\n DialogOpenChangeData,\n DialogOpenChangeEvent,\n DialogOpenChangeEventHandler,\n} from './Dialog';\n\nexport { DialogTrigger, useDialogTrigger_unstable, renderDialogTrigger_unstable } from './DialogTrigger';\nexport type {\n DialogTriggerProps,\n DialogTriggerChildProps,\n DialogTriggerState,\n DialogTriggerAction,\n} from './DialogTrigger';\n\nexport {\n DialogActions,\n dialogActionsClassNames,\n useDialogActions_unstable,\n useDialogActionsStyles_unstable,\n renderDialogActions_unstable,\n} from './DialogActions';\nexport type {\n DialogActionsProps,\n DialogActionsSlots,\n DialogActionsState,\n DialogActionsPosition,\n} from './DialogActions';\n\nexport {\n DialogBody,\n dialogBodyClassNames,\n useDialogBody_unstable,\n useDialogBodyStyles_unstable,\n renderDialogBody_unstable,\n} from './DialogBody';\nexport type { DialogBodyProps, DialogBodySlots, DialogBodyState } from './DialogBody';\n\nexport {\n DialogTitle,\n dialogTitleClassNames,\n useDialogTitle_unstable,\n useDialogTitleStyles_unstable,\n renderDialogTitle_unstable,\n} from './DialogTitle';\nexport type { DialogTitleProps, DialogTitleSlots, DialogTitleState } from './DialogTitle';\n\nexport {\n DialogSurface,\n dialogSurfaceClassNames,\n useDialogSurface_unstable,\n useDialogSurfaceStyles_unstable,\n renderDialogSurface_unstable,\n} from './DialogSurface';\nexport type { DialogSurfaceProps, DialogSurfaceSlots, DialogSurfaceState, DialogSurfaceElement } from './DialogSurface';\n\nexport {\n DialogContent,\n dialogContentClassNames,\n useDialogContent_unstable,\n useDialogContentStyles_unstable,\n renderDialogContent_unstable,\n} from './DialogContent';\nexport type { DialogContentProps, DialogContentSlots, DialogContentState } from './DialogContent';\n"],"mappings":"AAAA,SAASA,MAAM,EAAEC,qBAAqB,EAAEC,kBAAkB,QAAQ,UAAU;AAU5E,SAASC,aAAa,EAAEC,yBAAyB,EAAEC,4BAA4B,QAAQ,iBAAiB;AAQxG,SACEC,aAAa,EACbC,uBAAuB,EACvBC,yBAAyB,EACzBC,+BAA+B,EAC/BC,4BAA4B,QACvB,iBAAiB;AAQxB,SACEC,UAAU,EACVC,oBAAoB,EACpBC,sBAAsB,EACtBC,4BAA4B,EAC5BC,yBAAyB,QACpB,cAAc;AAGrB,SACEC,WAAW,EACXC,qBAAqB,EACrBC,uBAAuB,EACvBC,6BAA6B,EAC7BC,0BAA0B,QACrB,eAAe;AAGtB,SACEC,aAAa,EACbC,uBAAuB,EACvBC,yBAAyB,EACzBC,+BAA+B,EAC/BC,4BAA4B,QACvB,iBAAiB;AAGxB,SACEC,aAAa,EACbC,uBAAuB,EACvBC,yBAAyB,EACzBC,+BAA+B,EAC/BC,4BAA4B,QACvB,iBAAiB"}
1
+ {"version":3,"names":["Dialog","renderDialog_unstable","useDialog_unstable","DialogTrigger","useDialogTrigger_unstable","renderDialogTrigger_unstable","DialogActions","dialogActionsClassNames","useDialogActions_unstable","useDialogActionsStyles_unstable","renderDialogActions_unstable","DialogBody","dialogBodyClassNames","useDialogBody_unstable","useDialogBodyStyles_unstable","renderDialogBody_unstable","DialogTitle","dialogTitleClassNames","useDialogTitle_unstable","useDialogTitleStyles_unstable","renderDialogTitle_unstable","DialogSurface","dialogSurfaceClassNames","useDialogSurface_unstable","useDialogSurfaceStyles_unstable","renderDialogSurface_unstable","DialogContent","dialogContentClassNames","useDialogContent_unstable","useDialogContentStyles_unstable","renderDialogContent_unstable"],"sources":["../src/index.ts"],"sourcesContent":["export { Dialog, renderDialog_unstable, useDialog_unstable } from './Dialog';\nexport type {\n DialogSlots,\n DialogProps,\n DialogState,\n DialogOpenChangeData,\n DialogOpenChangeEvent,\n DialogOpenChangeEventHandler,\n} from './Dialog';\n\nexport { DialogTrigger, useDialogTrigger_unstable, renderDialogTrigger_unstable } from './DialogTrigger';\nexport type {\n DialogTriggerProps,\n DialogTriggerChildProps,\n DialogTriggerState,\n DialogTriggerAction,\n} from './DialogTrigger';\n\nexport {\n DialogActions,\n dialogActionsClassNames,\n useDialogActions_unstable,\n useDialogActionsStyles_unstable,\n renderDialogActions_unstable,\n} from './DialogActions';\nexport type {\n DialogActionsProps,\n DialogActionsSlots,\n DialogActionsState,\n DialogActionsPosition,\n} from './DialogActions';\n\nexport {\n DialogBody,\n dialogBodyClassNames,\n useDialogBody_unstable,\n useDialogBodyStyles_unstable,\n renderDialogBody_unstable,\n} from './DialogBody';\nexport type { DialogBodyProps, DialogBodySlots, DialogBodyState } from './DialogBody';\n\nexport {\n DialogTitle,\n dialogTitleClassNames,\n useDialogTitle_unstable,\n useDialogTitleStyles_unstable,\n renderDialogTitle_unstable,\n} from './DialogTitle';\nexport type { DialogTitleProps, DialogTitleSlots, DialogTitleState } from './DialogTitle';\n\nexport {\n DialogSurface,\n dialogSurfaceClassNames,\n useDialogSurface_unstable,\n useDialogSurfaceStyles_unstable,\n renderDialogSurface_unstable,\n} from './DialogSurface';\nexport type { DialogSurfaceProps, DialogSurfaceSlots, DialogSurfaceState, DialogSurfaceElement } from './DialogSurface';\n\nexport {\n DialogContent,\n dialogContentClassNames,\n useDialogContent_unstable,\n useDialogContentStyles_unstable,\n renderDialogContent_unstable,\n} from './DialogContent';\nexport type { DialogContentProps, DialogContentSlots, DialogContentState } from './DialogContent';\n"],"mappings":"AAAA,SAASA,MAAM,EAAEC,qBAAqB,EAAEC,kBAAkB,QAAQ;AAUlE,SAASC,aAAa,EAAEC,yBAAyB,EAAEC,4BAA4B,QAAQ;AAQvF,SACEC,aAAa,EACbC,uBAAuB,EACvBC,yBAAyB,EACzBC,+BAA+B,EAC/BC,4BAA4B,QACvB;AAQP,SACEC,UAAU,EACVC,oBAAoB,EACpBC,sBAAsB,EACtBC,4BAA4B,EAC5BC,yBAAyB,QACpB;AAGP,SACEC,WAAW,EACXC,qBAAqB,EACrBC,uBAAuB,EACvBC,6BAA6B,EAC7BC,0BAA0B,QACrB;AAGP,SACEC,aAAa,EACbC,uBAAuB,EACvBC,yBAAyB,EACzBC,+BAA+B,EAC/BC,4BAA4B,QACvB;AAGP,SACEC,aAAa,EACbC,uBAAuB,EACvBC,yBAAyB,EACzBC,+BAA+B,EAC/BC,4BAA4B,QACvB"}