@fluentui/react-table 9.0.0-alpha.1 → 9.0.0-alpha.10

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 (441) hide show
  1. package/CHANGELOG.json +501 -4
  2. package/CHANGELOG.md +139 -5
  3. package/dist/index.d.ts +653 -30
  4. package/lib/DataGrid.js +2 -0
  5. package/lib/DataGrid.js.map +1 -0
  6. package/lib/DataGridBody.js +2 -0
  7. package/lib/DataGridBody.js.map +1 -0
  8. package/lib/DataGridCell.js +2 -0
  9. package/lib/DataGridCell.js.map +1 -0
  10. package/lib/DataGridHeader.js +2 -0
  11. package/lib/DataGridHeader.js.map +1 -0
  12. package/lib/DataGridHeaderCell.js +2 -0
  13. package/lib/DataGridHeaderCell.js.map +1 -0
  14. package/lib/DataGridRow.js +2 -0
  15. package/lib/DataGridRow.js.map +1 -0
  16. package/lib/DataGridSelectionCell.js +2 -0
  17. package/lib/DataGridSelectionCell.js.map +1 -0
  18. package/lib/Table.js.map +1 -1
  19. package/lib/TableBody.js.map +1 -1
  20. package/lib/TableCell.js.map +1 -1
  21. package/lib/TableCellActions.js +2 -0
  22. package/lib/TableCellActions.js.map +1 -0
  23. package/lib/TableCellLayout.js +2 -0
  24. package/lib/TableCellLayout.js.map +1 -0
  25. package/lib/TableCellPrimaryLayout.js +2 -0
  26. package/lib/TableCellPrimaryLayout.js.map +1 -0
  27. package/lib/TableHeader.js.map +1 -1
  28. package/lib/TableHeaderCell.js.map +1 -1
  29. package/lib/TableRow.js.map +1 -1
  30. package/lib/TableSelectionCell.js +2 -0
  31. package/lib/TableSelectionCell.js.map +1 -0
  32. package/lib/components/DataGrid/DataGrid.js +16 -0
  33. package/lib/components/DataGrid/DataGrid.js.map +1 -0
  34. package/lib/components/DataGrid/DataGrid.types.js +2 -0
  35. package/lib/components/DataGrid/DataGrid.types.js.map +1 -0
  36. package/lib/components/DataGrid/index.js +6 -0
  37. package/lib/components/DataGrid/index.js.map +1 -0
  38. package/lib/components/DataGrid/renderDataGrid.js +9 -0
  39. package/lib/components/DataGrid/renderDataGrid.js.map +1 -0
  40. package/lib/components/DataGrid/useDataGrid.js +17 -0
  41. package/lib/components/DataGrid/useDataGrid.js.map +1 -0
  42. package/lib/components/DataGrid/useDataGridContextValues.js +5 -0
  43. package/lib/components/DataGrid/useDataGridContextValues.js.map +1 -0
  44. package/lib/components/DataGrid/useDataGridStyles.js +15 -0
  45. package/lib/components/DataGrid/useDataGridStyles.js.map +1 -0
  46. package/lib/components/DataGridBody/DataGridBody.js +15 -0
  47. package/lib/components/DataGridBody/DataGridBody.js.map +1 -0
  48. package/lib/components/DataGridBody/DataGridBody.types.js +2 -0
  49. package/lib/components/DataGridBody/DataGridBody.types.js.map +1 -0
  50. package/lib/components/DataGridBody/index.js +6 -0
  51. package/lib/components/DataGridBody/index.js.map +1 -0
  52. package/lib/components/DataGridBody/renderDataGridBody.js +9 -0
  53. package/lib/components/DataGridBody/renderDataGridBody.js.map +1 -0
  54. package/lib/components/DataGridBody/useDataGridBody.js +17 -0
  55. package/lib/components/DataGridBody/useDataGridBody.js.map +1 -0
  56. package/lib/components/DataGridBody/useDataGridBodyStyles.js +15 -0
  57. package/lib/components/DataGridBody/useDataGridBodyStyles.js.map +1 -0
  58. package/lib/components/DataGridCell/DataGridCell.js +15 -0
  59. package/lib/components/DataGridCell/DataGridCell.js.map +1 -0
  60. package/lib/components/DataGridCell/DataGridCell.types.js +2 -0
  61. package/lib/components/DataGridCell/DataGridCell.types.js.map +1 -0
  62. package/lib/components/DataGridCell/index.js +6 -0
  63. package/lib/components/DataGridCell/index.js.map +1 -0
  64. package/lib/components/DataGridCell/renderDataGridCell.js +9 -0
  65. package/lib/components/DataGridCell/renderDataGridCell.js.map +1 -0
  66. package/lib/components/DataGridCell/useDataGridCell.js +17 -0
  67. package/lib/components/DataGridCell/useDataGridCell.js.map +1 -0
  68. package/lib/components/DataGridCell/useDataGridCellStyles.js +15 -0
  69. package/lib/components/DataGridCell/useDataGridCellStyles.js.map +1 -0
  70. package/lib/components/DataGridHeader/DataGridHeader.js +15 -0
  71. package/lib/components/DataGridHeader/DataGridHeader.js.map +1 -0
  72. package/lib/components/DataGridHeader/DataGridHeader.types.js +2 -0
  73. package/lib/components/DataGridHeader/DataGridHeader.types.js.map +1 -0
  74. package/lib/components/DataGridHeader/index.js +6 -0
  75. package/lib/components/DataGridHeader/index.js.map +1 -0
  76. package/lib/components/DataGridHeader/renderDataGridHeader.js +9 -0
  77. package/lib/components/DataGridHeader/renderDataGridHeader.js.map +1 -0
  78. package/lib/components/DataGridHeader/useDataGridHeader.js +17 -0
  79. package/lib/components/DataGridHeader/useDataGridHeader.js.map +1 -0
  80. package/lib/components/DataGridHeader/useDataGridHeaderStyles.js +15 -0
  81. package/lib/components/DataGridHeader/useDataGridHeaderStyles.js.map +1 -0
  82. package/lib/components/DataGridHeaderCell/DataGridHeaderCell.js +15 -0
  83. package/lib/components/DataGridHeaderCell/DataGridHeaderCell.js.map +1 -0
  84. package/lib/components/DataGridHeaderCell/DataGridHeaderCell.types.js +2 -0
  85. package/lib/components/DataGridHeaderCell/DataGridHeaderCell.types.js.map +1 -0
  86. package/lib/components/DataGridHeaderCell/index.js +6 -0
  87. package/lib/components/DataGridHeaderCell/index.js.map +1 -0
  88. package/lib/components/DataGridHeaderCell/renderDataGridHeaderCell.js +9 -0
  89. package/lib/components/DataGridHeaderCell/renderDataGridHeaderCell.js.map +1 -0
  90. package/lib/components/DataGridHeaderCell/useDataGridHeaderCell.js +17 -0
  91. package/lib/components/DataGridHeaderCell/useDataGridHeaderCell.js.map +1 -0
  92. package/lib/components/DataGridHeaderCell/useDataGridHeaderCellStyles.js +26 -0
  93. package/lib/components/DataGridHeaderCell/useDataGridHeaderCellStyles.js.map +1 -0
  94. package/lib/components/DataGridRow/DataGridRow.js +15 -0
  95. package/lib/components/DataGridRow/DataGridRow.js.map +1 -0
  96. package/lib/components/DataGridRow/DataGridRow.types.js +2 -0
  97. package/lib/components/DataGridRow/DataGridRow.types.js.map +1 -0
  98. package/lib/components/DataGridRow/index.js +6 -0
  99. package/lib/components/DataGridRow/index.js.map +1 -0
  100. package/lib/components/DataGridRow/renderDataGridRow.js +9 -0
  101. package/lib/components/DataGridRow/renderDataGridRow.js.map +1 -0
  102. package/lib/components/DataGridRow/useDataGridRow.js +17 -0
  103. package/lib/components/DataGridRow/useDataGridRow.js.map +1 -0
  104. package/lib/components/DataGridRow/useDataGridRowStyles.js +15 -0
  105. package/lib/components/DataGridRow/useDataGridRowStyles.js.map +1 -0
  106. package/lib/components/DataGridSelectionCell/DataGridSelectionCell.js +15 -0
  107. package/lib/components/DataGridSelectionCell/DataGridSelectionCell.js.map +1 -0
  108. package/lib/components/DataGridSelectionCell/DataGridSelectionCell.types.js +2 -0
  109. package/lib/components/DataGridSelectionCell/DataGridSelectionCell.types.js.map +1 -0
  110. package/lib/components/DataGridSelectionCell/index.js +6 -0
  111. package/lib/components/DataGridSelectionCell/index.js.map +1 -0
  112. package/lib/components/DataGridSelectionCell/renderDataGridSelectionCell.js +9 -0
  113. package/lib/components/DataGridSelectionCell/renderDataGridSelectionCell.js.map +1 -0
  114. package/lib/components/DataGridSelectionCell/useDataGridSelectionCell.js +17 -0
  115. package/lib/components/DataGridSelectionCell/useDataGridSelectionCell.js.map +1 -0
  116. package/lib/components/DataGridSelectionCell/useDataGridSelectionCellStyles.js +26 -0
  117. package/lib/components/DataGridSelectionCell/useDataGridSelectionCellStyles.js.map +1 -0
  118. package/lib/components/Table/Table.js.map +1 -1
  119. package/lib/components/Table/Table.types.js.map +1 -1
  120. package/lib/components/Table/index.js.map +1 -1
  121. package/lib/components/Table/renderTable.js.map +1 -1
  122. package/lib/components/Table/useTable.js.map +1 -1
  123. package/lib/components/Table/useTableContextValues.js +7 -5
  124. package/lib/components/Table/useTableContextValues.js.map +1 -1
  125. package/lib/components/Table/useTableStyles.js +29 -3
  126. package/lib/components/Table/useTableStyles.js.map +1 -1
  127. package/lib/components/TableBody/TableBody.js.map +1 -1
  128. package/lib/components/TableBody/TableBody.types.js.map +1 -1
  129. package/lib/components/TableBody/index.js.map +1 -1
  130. package/lib/components/TableBody/renderTableBody.js.map +1 -1
  131. package/lib/components/TableBody/useTableBody.js +5 -2
  132. package/lib/components/TableBody/useTableBody.js.map +1 -1
  133. package/lib/components/TableBody/useTableBodyStyles.js +23 -2
  134. package/lib/components/TableBody/useTableBodyStyles.js.map +1 -1
  135. package/lib/components/TableCell/TableCell.js.map +1 -1
  136. package/lib/components/TableCell/TableCell.types.js.map +1 -1
  137. package/lib/components/TableCell/index.js.map +1 -1
  138. package/lib/components/TableCell/renderTableCell.js +2 -4
  139. package/lib/components/TableCell/renderTableCell.js.map +1 -1
  140. package/lib/components/TableCell/useTableCell.js +7 -6
  141. package/lib/components/TableCell/useTableCell.js.map +1 -1
  142. package/lib/components/TableCell/useTableCellStyles.js +32 -21
  143. package/lib/components/TableCell/useTableCellStyles.js.map +1 -1
  144. package/lib/components/TableCellActions/TableCellActions.js +15 -0
  145. package/lib/components/TableCellActions/TableCellActions.js.map +1 -0
  146. package/lib/components/TableCellActions/TableCellActions.types.js +2 -0
  147. package/lib/components/TableCellActions/TableCellActions.types.js.map +1 -0
  148. package/lib/components/TableCellActions/index.js +6 -0
  149. package/lib/components/TableCellActions/index.js.map +1 -0
  150. package/lib/components/TableCellActions/renderTableCellActions.js +16 -0
  151. package/lib/components/TableCellActions/renderTableCellActions.js.map +1 -0
  152. package/lib/components/TableCellActions/useTableCellActions.js +27 -0
  153. package/lib/components/TableCellActions/useTableCellActions.js.map +1 -0
  154. package/lib/components/TableCellActions/useTableCellActionsStyles.js +40 -0
  155. package/lib/components/TableCellActions/useTableCellActionsStyles.js.map +1 -0
  156. package/lib/components/TableCellLayout/TableCellLayout.js +16 -0
  157. package/lib/components/TableCellLayout/TableCellLayout.js.map +1 -0
  158. package/lib/components/TableCellLayout/TableCellLayout.types.js +2 -0
  159. package/lib/components/TableCellLayout/TableCellLayout.types.js.map +1 -0
  160. package/lib/components/TableCellLayout/index.js +6 -0
  161. package/lib/components/TableCellLayout/index.js.map +1 -0
  162. package/lib/components/TableCellLayout/renderTableCellLayout.js +22 -0
  163. package/lib/components/TableCellLayout/renderTableCellLayout.js.map +1 -0
  164. package/lib/components/TableCellLayout/useTableCellLayout.js +46 -0
  165. package/lib/components/TableCellLayout/useTableCellLayout.js.map +1 -0
  166. package/lib/components/TableCellLayout/useTableCellLayoutContextValues.js +13 -0
  167. package/lib/components/TableCellLayout/useTableCellLayoutContextValues.js.map +1 -0
  168. package/lib/components/TableCellLayout/useTableCellLayoutStyles.js +74 -0
  169. package/lib/components/TableCellLayout/useTableCellLayoutStyles.js.map +1 -0
  170. package/lib/components/TableHeader/TableHeader.js.map +1 -1
  171. package/lib/components/TableHeader/TableHeader.types.js.map +1 -1
  172. package/lib/components/TableHeader/index.js.map +1 -1
  173. package/lib/components/TableHeader/renderTableHeader.js +5 -2
  174. package/lib/components/TableHeader/renderTableHeader.js.map +1 -1
  175. package/lib/components/TableHeader/useTableHeader.js +6 -3
  176. package/lib/components/TableHeader/useTableHeader.js.map +1 -1
  177. package/lib/components/TableHeader/useTableHeaderStyles.js +29 -2
  178. package/lib/components/TableHeader/useTableHeaderStyles.js.map +1 -1
  179. package/lib/components/TableHeaderCell/TableHeaderCell.js.map +1 -1
  180. package/lib/components/TableHeaderCell/TableHeaderCell.types.js.map +1 -1
  181. package/lib/components/TableHeaderCell/index.js.map +1 -1
  182. package/lib/components/TableHeaderCell/renderTableHeaderCell.js.map +1 -1
  183. package/lib/components/TableHeaderCell/useTableHeaderCell.js +6 -3
  184. package/lib/components/TableHeaderCell/useTableHeaderCell.js.map +1 -1
  185. package/lib/components/TableHeaderCell/useTableHeaderCellStyles.js +42 -10
  186. package/lib/components/TableHeaderCell/useTableHeaderCellStyles.js.map +1 -1
  187. package/lib/components/TableRow/TableRow.js.map +1 -1
  188. package/lib/components/TableRow/TableRow.types.js.map +1 -1
  189. package/lib/components/TableRow/index.js.map +1 -1
  190. package/lib/components/TableRow/renderTableRow.js.map +1 -1
  191. package/lib/components/TableRow/useTableRow.js +12 -6
  192. package/lib/components/TableRow/useTableRow.js.map +1 -1
  193. package/lib/components/TableRow/useTableRowStyles.js +202 -9
  194. package/lib/components/TableRow/useTableRowStyles.js.map +1 -1
  195. package/lib/components/TableSelectionCell/TableSelectionCell.js +15 -0
  196. package/lib/components/TableSelectionCell/TableSelectionCell.js.map +1 -0
  197. package/lib/components/TableSelectionCell/TableSelectionCell.types.js +2 -0
  198. package/lib/components/TableSelectionCell/TableSelectionCell.types.js.map +1 -0
  199. package/lib/components/TableSelectionCell/index.js +6 -0
  200. package/lib/components/TableSelectionCell/index.js.map +1 -0
  201. package/lib/components/TableSelectionCell/renderTableSelectionCell.js +17 -0
  202. package/lib/components/TableSelectionCell/renderTableSelectionCell.js.map +1 -0
  203. package/lib/components/TableSelectionCell/useTableSelectionCell.js +51 -0
  204. package/lib/components/TableSelectionCell/useTableSelectionCell.js.map +1 -0
  205. package/lib/components/TableSelectionCell/useTableSelectionCellStyles.js +90 -0
  206. package/lib/components/TableSelectionCell/useTableSelectionCellStyles.js.map +1 -0
  207. package/lib/contexts/tableContext.js +7 -3
  208. package/lib/contexts/tableContext.js.map +1 -1
  209. package/lib/contexts/tableHeaderContext.js +6 -0
  210. package/lib/contexts/tableHeaderContext.js.map +1 -0
  211. package/lib/hooks/index.js +5 -0
  212. package/lib/hooks/index.js.map +1 -0
  213. package/lib/hooks/selectionManager.js +89 -0
  214. package/lib/hooks/selectionManager.js.map +1 -0
  215. package/lib/hooks/types.js +2 -0
  216. package/lib/hooks/types.js.map +1 -0
  217. package/lib/hooks/useSelection.js +74 -0
  218. package/lib/hooks/useSelection.js.map +1 -0
  219. package/lib/hooks/useSort.js +94 -0
  220. package/lib/hooks/useSort.js.map +1 -0
  221. package/lib/hooks/useTable.js +32 -0
  222. package/lib/hooks/useTable.js.map +1 -0
  223. package/lib/index.js +11 -0
  224. package/lib/index.js.map +1 -1
  225. package/lib-commonjs/DataGrid.js +10 -0
  226. package/lib-commonjs/DataGrid.js.map +1 -0
  227. package/lib-commonjs/DataGridBody.js +10 -0
  228. package/lib-commonjs/DataGridBody.js.map +1 -0
  229. package/lib-commonjs/DataGridCell.js +10 -0
  230. package/lib-commonjs/DataGridCell.js.map +1 -0
  231. package/lib-commonjs/DataGridHeader.js +10 -0
  232. package/lib-commonjs/DataGridHeader.js.map +1 -0
  233. package/lib-commonjs/DataGridHeaderCell.js +10 -0
  234. package/lib-commonjs/DataGridHeaderCell.js.map +1 -0
  235. package/lib-commonjs/DataGridRow.js +10 -0
  236. package/lib-commonjs/DataGridRow.js.map +1 -0
  237. package/lib-commonjs/DataGridSelectionCell.js +10 -0
  238. package/lib-commonjs/DataGridSelectionCell.js.map +1 -0
  239. package/lib-commonjs/Table.js.map +1 -1
  240. package/lib-commonjs/TableBody.js.map +1 -1
  241. package/lib-commonjs/TableCell.js.map +1 -1
  242. package/lib-commonjs/TableCellActions.js +10 -0
  243. package/lib-commonjs/TableCellActions.js.map +1 -0
  244. package/lib-commonjs/TableCellLayout.js +10 -0
  245. package/lib-commonjs/TableCellLayout.js.map +1 -0
  246. package/lib-commonjs/TableCellPrimaryLayout.js +10 -0
  247. package/lib-commonjs/TableCellPrimaryLayout.js.map +1 -0
  248. package/lib-commonjs/TableHeader.js.map +1 -1
  249. package/lib-commonjs/TableHeaderCell.js.map +1 -1
  250. package/lib-commonjs/TableRow.js.map +1 -1
  251. package/lib-commonjs/TableSelectionCell.js +10 -0
  252. package/lib-commonjs/TableSelectionCell.js.map +1 -0
  253. package/lib-commonjs/components/DataGrid/DataGrid.js +28 -0
  254. package/lib-commonjs/components/DataGrid/DataGrid.js.map +1 -0
  255. package/lib-commonjs/components/DataGrid/DataGrid.types.js +6 -0
  256. package/lib-commonjs/components/DataGrid/DataGrid.types.js.map +1 -0
  257. package/lib-commonjs/components/DataGrid/index.js +18 -0
  258. package/lib-commonjs/components/DataGrid/index.js.map +1 -0
  259. package/lib-commonjs/components/DataGrid/renderDataGrid.js +19 -0
  260. package/lib-commonjs/components/DataGrid/renderDataGrid.js.map +1 -0
  261. package/lib-commonjs/components/DataGrid/useDataGrid.js +27 -0
  262. package/lib-commonjs/components/DataGrid/useDataGrid.js.map +1 -0
  263. package/lib-commonjs/components/DataGrid/useDataGridContextValues.js +15 -0
  264. package/lib-commonjs/components/DataGrid/useDataGridContextValues.js.map +1 -0
  265. package/lib-commonjs/components/DataGrid/useDataGridStyles.js +26 -0
  266. package/lib-commonjs/components/DataGrid/useDataGridStyles.js.map +1 -0
  267. package/lib-commonjs/components/DataGridBody/DataGridBody.js +26 -0
  268. package/lib-commonjs/components/DataGridBody/DataGridBody.js.map +1 -0
  269. package/lib-commonjs/components/DataGridBody/DataGridBody.types.js +6 -0
  270. package/lib-commonjs/components/DataGridBody/DataGridBody.types.js.map +1 -0
  271. package/lib-commonjs/components/DataGridBody/index.js +18 -0
  272. package/lib-commonjs/components/DataGridBody/index.js.map +1 -0
  273. package/lib-commonjs/components/DataGridBody/renderDataGridBody.js +19 -0
  274. package/lib-commonjs/components/DataGridBody/renderDataGridBody.js.map +1 -0
  275. package/lib-commonjs/components/DataGridBody/useDataGridBody.js +27 -0
  276. package/lib-commonjs/components/DataGridBody/useDataGridBody.js.map +1 -0
  277. package/lib-commonjs/components/DataGridBody/useDataGridBodyStyles.js +26 -0
  278. package/lib-commonjs/components/DataGridBody/useDataGridBodyStyles.js.map +1 -0
  279. package/lib-commonjs/components/DataGridCell/DataGridCell.js +26 -0
  280. package/lib-commonjs/components/DataGridCell/DataGridCell.js.map +1 -0
  281. package/lib-commonjs/components/DataGridCell/DataGridCell.types.js +6 -0
  282. package/lib-commonjs/components/DataGridCell/DataGridCell.types.js.map +1 -0
  283. package/lib-commonjs/components/DataGridCell/index.js +18 -0
  284. package/lib-commonjs/components/DataGridCell/index.js.map +1 -0
  285. package/lib-commonjs/components/DataGridCell/renderDataGridCell.js +19 -0
  286. package/lib-commonjs/components/DataGridCell/renderDataGridCell.js.map +1 -0
  287. package/lib-commonjs/components/DataGridCell/useDataGridCell.js +27 -0
  288. package/lib-commonjs/components/DataGridCell/useDataGridCell.js.map +1 -0
  289. package/lib-commonjs/components/DataGridCell/useDataGridCellStyles.js +26 -0
  290. package/lib-commonjs/components/DataGridCell/useDataGridCellStyles.js.map +1 -0
  291. package/lib-commonjs/components/DataGridHeader/DataGridHeader.js +26 -0
  292. package/lib-commonjs/components/DataGridHeader/DataGridHeader.js.map +1 -0
  293. package/lib-commonjs/components/DataGridHeader/DataGridHeader.types.js +6 -0
  294. package/lib-commonjs/components/DataGridHeader/DataGridHeader.types.js.map +1 -0
  295. package/lib-commonjs/components/DataGridHeader/index.js +18 -0
  296. package/lib-commonjs/components/DataGridHeader/index.js.map +1 -0
  297. package/lib-commonjs/components/DataGridHeader/renderDataGridHeader.js +19 -0
  298. package/lib-commonjs/components/DataGridHeader/renderDataGridHeader.js.map +1 -0
  299. package/lib-commonjs/components/DataGridHeader/useDataGridHeader.js +27 -0
  300. package/lib-commonjs/components/DataGridHeader/useDataGridHeader.js.map +1 -0
  301. package/lib-commonjs/components/DataGridHeader/useDataGridHeaderStyles.js +26 -0
  302. package/lib-commonjs/components/DataGridHeader/useDataGridHeaderStyles.js.map +1 -0
  303. package/lib-commonjs/components/DataGridHeaderCell/DataGridHeaderCell.js +26 -0
  304. package/lib-commonjs/components/DataGridHeaderCell/DataGridHeaderCell.js.map +1 -0
  305. package/lib-commonjs/components/DataGridHeaderCell/DataGridHeaderCell.types.js +6 -0
  306. package/lib-commonjs/components/DataGridHeaderCell/DataGridHeaderCell.types.js.map +1 -0
  307. package/lib-commonjs/components/DataGridHeaderCell/index.js +18 -0
  308. package/lib-commonjs/components/DataGridHeaderCell/index.js.map +1 -0
  309. package/lib-commonjs/components/DataGridHeaderCell/renderDataGridHeaderCell.js +19 -0
  310. package/lib-commonjs/components/DataGridHeaderCell/renderDataGridHeaderCell.js.map +1 -0
  311. package/lib-commonjs/components/DataGridHeaderCell/useDataGridHeaderCell.js +27 -0
  312. package/lib-commonjs/components/DataGridHeaderCell/useDataGridHeaderCell.js.map +1 -0
  313. package/lib-commonjs/components/DataGridHeaderCell/useDataGridHeaderCellStyles.js +37 -0
  314. package/lib-commonjs/components/DataGridHeaderCell/useDataGridHeaderCellStyles.js.map +1 -0
  315. package/lib-commonjs/components/DataGridRow/DataGridRow.js +26 -0
  316. package/lib-commonjs/components/DataGridRow/DataGridRow.js.map +1 -0
  317. package/lib-commonjs/components/DataGridRow/DataGridRow.types.js +6 -0
  318. package/lib-commonjs/components/DataGridRow/DataGridRow.types.js.map +1 -0
  319. package/lib-commonjs/components/DataGridRow/index.js +18 -0
  320. package/lib-commonjs/components/DataGridRow/index.js.map +1 -0
  321. package/lib-commonjs/components/DataGridRow/renderDataGridRow.js +19 -0
  322. package/lib-commonjs/components/DataGridRow/renderDataGridRow.js.map +1 -0
  323. package/lib-commonjs/components/DataGridRow/useDataGridRow.js +27 -0
  324. package/lib-commonjs/components/DataGridRow/useDataGridRow.js.map +1 -0
  325. package/lib-commonjs/components/DataGridRow/useDataGridRowStyles.js +26 -0
  326. package/lib-commonjs/components/DataGridRow/useDataGridRowStyles.js.map +1 -0
  327. package/lib-commonjs/components/DataGridSelectionCell/DataGridSelectionCell.js +26 -0
  328. package/lib-commonjs/components/DataGridSelectionCell/DataGridSelectionCell.js.map +1 -0
  329. package/lib-commonjs/components/DataGridSelectionCell/DataGridSelectionCell.types.js +6 -0
  330. package/lib-commonjs/components/DataGridSelectionCell/DataGridSelectionCell.types.js.map +1 -0
  331. package/lib-commonjs/components/DataGridSelectionCell/index.js +18 -0
  332. package/lib-commonjs/components/DataGridSelectionCell/index.js.map +1 -0
  333. package/lib-commonjs/components/DataGridSelectionCell/renderDataGridSelectionCell.js +19 -0
  334. package/lib-commonjs/components/DataGridSelectionCell/renderDataGridSelectionCell.js.map +1 -0
  335. package/lib-commonjs/components/DataGridSelectionCell/useDataGridSelectionCell.js +27 -0
  336. package/lib-commonjs/components/DataGridSelectionCell/useDataGridSelectionCell.js.map +1 -0
  337. package/lib-commonjs/components/DataGridSelectionCell/useDataGridSelectionCellStyles.js +37 -0
  338. package/lib-commonjs/components/DataGridSelectionCell/useDataGridSelectionCellStyles.js.map +1 -0
  339. package/lib-commonjs/components/Table/Table.js.map +1 -1
  340. package/lib-commonjs/components/Table/index.js.map +1 -1
  341. package/lib-commonjs/components/Table/renderTable.js.map +1 -1
  342. package/lib-commonjs/components/Table/useTable.js.map +1 -1
  343. package/lib-commonjs/components/Table/useTableContextValues.js +8 -5
  344. package/lib-commonjs/components/Table/useTableContextValues.js.map +1 -1
  345. package/lib-commonjs/components/Table/useTableStyles.js +30 -3
  346. package/lib-commonjs/components/Table/useTableStyles.js.map +1 -1
  347. package/lib-commonjs/components/TableBody/TableBody.js.map +1 -1
  348. package/lib-commonjs/components/TableBody/index.js.map +1 -1
  349. package/lib-commonjs/components/TableBody/renderTableBody.js.map +1 -1
  350. package/lib-commonjs/components/TableBody/useTableBody.js +5 -2
  351. package/lib-commonjs/components/TableBody/useTableBody.js.map +1 -1
  352. package/lib-commonjs/components/TableBody/useTableBodyStyles.js +21 -1
  353. package/lib-commonjs/components/TableBody/useTableBodyStyles.js.map +1 -1
  354. package/lib-commonjs/components/TableCell/TableCell.js.map +1 -1
  355. package/lib-commonjs/components/TableCell/index.js.map +1 -1
  356. package/lib-commonjs/components/TableCell/renderTableCell.js +2 -4
  357. package/lib-commonjs/components/TableCell/renderTableCell.js.map +1 -1
  358. package/lib-commonjs/components/TableCell/useTableCell.js +6 -5
  359. package/lib-commonjs/components/TableCell/useTableCell.js.map +1 -1
  360. package/lib-commonjs/components/TableCell/useTableCellStyles.js +32 -21
  361. package/lib-commonjs/components/TableCell/useTableCellStyles.js.map +1 -1
  362. package/lib-commonjs/components/TableCellActions/TableCellActions.js +26 -0
  363. package/lib-commonjs/components/TableCellActions/TableCellActions.js.map +1 -0
  364. package/lib-commonjs/components/TableCellActions/TableCellActions.types.js +6 -0
  365. package/lib-commonjs/components/TableCellActions/TableCellActions.types.js.map +1 -0
  366. package/lib-commonjs/components/TableCellActions/index.js +18 -0
  367. package/lib-commonjs/components/TableCellActions/index.js.map +1 -0
  368. package/lib-commonjs/components/TableCellActions/renderTableCellActions.js +27 -0
  369. package/lib-commonjs/components/TableCellActions/renderTableCellActions.js.map +1 -0
  370. package/lib-commonjs/components/TableCellActions/useTableCellActions.js +38 -0
  371. package/lib-commonjs/components/TableCellActions/useTableCellActions.js.map +1 -0
  372. package/lib-commonjs/components/TableCellActions/useTableCellActionsStyles.js +51 -0
  373. package/lib-commonjs/components/TableCellActions/useTableCellActionsStyles.js.map +1 -0
  374. package/lib-commonjs/components/TableCellLayout/TableCellLayout.js +28 -0
  375. package/lib-commonjs/components/TableCellLayout/TableCellLayout.js.map +1 -0
  376. package/lib-commonjs/components/TableCellLayout/TableCellLayout.types.js +6 -0
  377. package/lib-commonjs/components/TableCellLayout/TableCellLayout.types.js.map +1 -0
  378. package/lib-commonjs/components/TableCellLayout/index.js +18 -0
  379. package/lib-commonjs/components/TableCellLayout/index.js.map +1 -0
  380. package/lib-commonjs/components/TableCellLayout/renderTableCellLayout.js +34 -0
  381. package/lib-commonjs/components/TableCellLayout/renderTableCellLayout.js.map +1 -0
  382. package/lib-commonjs/components/TableCellLayout/useTableCellLayout.js +57 -0
  383. package/lib-commonjs/components/TableCellLayout/useTableCellLayout.js.map +1 -0
  384. package/lib-commonjs/components/TableCellLayout/useTableCellLayoutContextValues.js +23 -0
  385. package/lib-commonjs/components/TableCellLayout/useTableCellLayoutContextValues.js.map +1 -0
  386. package/lib-commonjs/components/TableCellLayout/useTableCellLayoutStyles.js +85 -0
  387. package/lib-commonjs/components/TableCellLayout/useTableCellLayoutStyles.js.map +1 -0
  388. package/lib-commonjs/components/TableHeader/TableHeader.js.map +1 -1
  389. package/lib-commonjs/components/TableHeader/index.js.map +1 -1
  390. package/lib-commonjs/components/TableHeader/renderTableHeader.js +6 -2
  391. package/lib-commonjs/components/TableHeader/renderTableHeader.js.map +1 -1
  392. package/lib-commonjs/components/TableHeader/useTableHeader.js +6 -3
  393. package/lib-commonjs/components/TableHeader/useTableHeader.js.map +1 -1
  394. package/lib-commonjs/components/TableHeader/useTableHeaderStyles.js +28 -1
  395. package/lib-commonjs/components/TableHeader/useTableHeaderStyles.js.map +1 -1
  396. package/lib-commonjs/components/TableHeaderCell/TableHeaderCell.js.map +1 -1
  397. package/lib-commonjs/components/TableHeaderCell/index.js.map +1 -1
  398. package/lib-commonjs/components/TableHeaderCell/renderTableHeaderCell.js.map +1 -1
  399. package/lib-commonjs/components/TableHeaderCell/useTableHeaderCell.js +6 -3
  400. package/lib-commonjs/components/TableHeaderCell/useTableHeaderCell.js.map +1 -1
  401. package/lib-commonjs/components/TableHeaderCell/useTableHeaderCellStyles.js +42 -10
  402. package/lib-commonjs/components/TableHeaderCell/useTableHeaderCellStyles.js.map +1 -1
  403. package/lib-commonjs/components/TableRow/TableRow.js.map +1 -1
  404. package/lib-commonjs/components/TableRow/index.js.map +1 -1
  405. package/lib-commonjs/components/TableRow/renderTableRow.js.map +1 -1
  406. package/lib-commonjs/components/TableRow/useTableRow.js +12 -5
  407. package/lib-commonjs/components/TableRow/useTableRow.js.map +1 -1
  408. package/lib-commonjs/components/TableRow/useTableRowStyles.js +206 -9
  409. package/lib-commonjs/components/TableRow/useTableRowStyles.js.map +1 -1
  410. package/lib-commonjs/components/TableSelectionCell/TableSelectionCell.js +26 -0
  411. package/lib-commonjs/components/TableSelectionCell/TableSelectionCell.js.map +1 -0
  412. package/lib-commonjs/components/TableSelectionCell/TableSelectionCell.types.js +6 -0
  413. package/lib-commonjs/components/TableSelectionCell/TableSelectionCell.types.js.map +1 -0
  414. package/lib-commonjs/components/TableSelectionCell/index.js +18 -0
  415. package/lib-commonjs/components/TableSelectionCell/index.js.map +1 -0
  416. package/lib-commonjs/components/TableSelectionCell/renderTableSelectionCell.js +28 -0
  417. package/lib-commonjs/components/TableSelectionCell/renderTableSelectionCell.js.map +1 -0
  418. package/lib-commonjs/components/TableSelectionCell/useTableSelectionCell.js +65 -0
  419. package/lib-commonjs/components/TableSelectionCell/useTableSelectionCell.js.map +1 -0
  420. package/lib-commonjs/components/TableSelectionCell/useTableSelectionCellStyles.js +101 -0
  421. package/lib-commonjs/components/TableSelectionCell/useTableSelectionCellStyles.js.map +1 -0
  422. package/lib-commonjs/contexts/tableContext.js +7 -3
  423. package/lib-commonjs/contexts/tableContext.js.map +1 -1
  424. package/lib-commonjs/contexts/tableHeaderContext.js +17 -0
  425. package/lib-commonjs/contexts/tableHeaderContext.js.map +1 -0
  426. package/lib-commonjs/hooks/index.js +16 -0
  427. package/lib-commonjs/hooks/index.js.map +1 -0
  428. package/lib-commonjs/hooks/selectionManager.js +98 -0
  429. package/lib-commonjs/hooks/selectionManager.js.map +1 -0
  430. package/lib-commonjs/hooks/types.js +6 -0
  431. package/lib-commonjs/hooks/types.js.map +1 -0
  432. package/lib-commonjs/hooks/useSelection.js +89 -0
  433. package/lib-commonjs/hooks/useSelection.js.map +1 -0
  434. package/lib-commonjs/hooks/useSort.js +107 -0
  435. package/lib-commonjs/hooks/useSort.js.map +1 -0
  436. package/lib-commonjs/hooks/useTable.js +42 -0
  437. package/lib-commonjs/hooks/useTable.js.map +1 -0
  438. package/lib-commonjs/index.js +353 -1
  439. package/lib-commonjs/index.js.map +1 -1
  440. package/package.json +26 -17
  441. package/dist/tsdoc-metadata.json +0 -11
@@ -7,20 +7,43 @@ exports.useTableStyles_unstable = exports.tableClassNames = exports.tableClassNa
7
7
 
8
8
  const react_1 = /*#__PURE__*/require("@griffel/react");
9
9
 
10
+ const react_theme_1 = /*#__PURE__*/require("@fluentui/react-theme");
11
+
10
12
  exports.tableClassName = 'fui-Table';
11
13
  exports.tableClassNames = {
12
14
  root: 'fui-Table'
13
15
  };
16
+
17
+ const useTableLayoutStyles = /*#__PURE__*/react_1.__styles({
18
+ "root": {
19
+ "mc9l5x": "f1w4nmp0",
20
+ "ha4doy": "fmrv4ls",
21
+ "a9b677": "fly5x3f",
22
+ "B73mfa3": "f14m3nip"
23
+ }
24
+ }, {
25
+ "d": [".f1w4nmp0{display:table;}", ".fmrv4ls{vertical-align:middle;}", ".fly5x3f{width:100%;}", ".f14m3nip{table-layout:fixed;}"]
26
+ });
27
+
28
+ const useFlexLayoutStyles = /*#__PURE__*/react_1.__styles({
29
+ "root": {
30
+ "mc9l5x": "ftgm304"
31
+ }
32
+ }, {
33
+ "d": [".ftgm304{display:block;}"]
34
+ });
14
35
  /**
15
36
  * Styles for the root slot
16
37
  */
17
38
 
39
+
18
40
  const useStyles = /*#__PURE__*/react_1.__styles({
19
41
  "root": {
20
- "a9b677": "fly5x3f"
42
+ "po53p8": "fgkb47j",
43
+ "De3pzq": "fhovq9v"
21
44
  }
22
45
  }, {
23
- "d": [".fly5x3f{width:100%;}"]
46
+ "d": [".fgkb47j{border-collapse:collapse;}", ".fhovq9v{background-color:var(--colorSubtleBackground);}"]
24
47
  });
25
48
  /**
26
49
  * Apply styling to the Table slots based on the state
@@ -29,7 +52,11 @@ const useStyles = /*#__PURE__*/react_1.__styles({
29
52
 
30
53
  const useTableStyles_unstable = state => {
31
54
  const styles = useStyles();
32
- state.root.className = react_1.mergeClasses(exports.tableClassName, styles.root, state.root.className);
55
+ const layoutStyles = {
56
+ table: useTableLayoutStyles(),
57
+ flex: useFlexLayoutStyles()
58
+ };
59
+ state.root.className = react_1.mergeClasses(exports.tableClassName, styles.root, state.noNativeElements ? layoutStyles.flex.root : layoutStyles.table.root, state.root.className);
33
60
  return state;
34
61
  };
35
62
 
@@ -1 +1 @@
1
- {"version":3,"sources":["components/Table/useTableStyles.ts"],"names":[],"mappings":";;;;;;;AAAA,MAAA,OAAA,gBAAA,OAAA,CAAA,gBAAA,CAAA;;AAIa,OAAA,CAAA,cAAA,GAAiB,WAAjB;AACA,OAAA,CAAA,eAAA,GAA8C;EACzD,IAAI,EAAE;AADmD,CAA9C;AAIb;;AAEG;;AACH,MAAM,SAAS,gBAAG,OAAA,SAAA;EAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAAlB;AAMA;;AAEG;;;AACI,MAAM,uBAAuB,GAAI,KAAD,IAAkC;EACvE,MAAM,MAAM,GAAG,SAAS,EAAxB;EACA,KAAK,CAAC,IAAN,CAAW,SAAX,GAAuB,OAAA,CAAA,YAAA,CAAa,OAAA,CAAA,cAAb,EAA6B,MAAM,CAAC,IAApC,EAA0C,KAAK,CAAC,IAAN,CAAW,SAArD,CAAvB;EAEA,OAAO,KAAP;AACD,CALM;;AAAM,OAAA,CAAA,uBAAA,GAAuB,uBAAvB","sourcesContent":["import { makeStyles, mergeClasses } from '@griffel/react';\nimport type { TableSlots, TableState } from './Table.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\n\nexport const tableClassName = 'fui-Table';\nexport const tableClassNames: SlotClassNames<TableSlots> = {\n root: 'fui-Table',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n width: '100%',\n },\n});\n\n/**\n * Apply styling to the Table slots based on the state\n */\nexport const useTableStyles_unstable = (state: TableState): TableState => {\n const styles = useStyles();\n state.root.className = mergeClasses(tableClassName, styles.root, state.root.className);\n\n return state;\n};\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/Table/useTableStyles.ts"],"names":[],"mappings":";;;;;;;AAAA,MAAA,OAAA,gBAAA,OAAA,CAAA,gBAAA,CAAA;;AACA,MAAA,aAAA,gBAAA,OAAA,CAAA,uBAAA,CAAA;;AAIa,OAAA,CAAA,cAAA,GAAiB,WAAjB;AACA,OAAA,CAAA,eAAA,GAA8C;EACzD,IAAI,EAAE;AADmD,CAA9C;;AAIb,MAAM,oBAAoB,gBAAG,OAAA,SAAA;EAAA;IAAA;IAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAA7B;;AASA,MAAM,mBAAmB,gBAAG,OAAA,SAAA;EAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAA5B;AAMA;;AAEG;;;AACH,MAAM,SAAS,gBAAG,OAAA,SAAA;EAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAAlB;AAOA;;AAEG;;;AACI,MAAM,uBAAuB,GAAI,KAAD,IAAkC;EACvE,MAAM,MAAM,GAAG,SAAS,EAAxB;EACA,MAAM,YAAY,GAAG;IACnB,KAAK,EAAE,oBAAoB,EADR;IAEnB,IAAI,EAAE,mBAAmB;EAFN,CAArB;EAIA,KAAK,CAAC,IAAN,CAAW,SAAX,GAAuB,OAAA,CAAA,YAAA,CACrB,OAAA,CAAA,cADqB,EAErB,MAAM,CAAC,IAFc,EAGrB,KAAK,CAAC,gBAAN,GAAyB,YAAY,CAAC,IAAb,CAAkB,IAA3C,GAAkD,YAAY,CAAC,KAAb,CAAmB,IAHhD,EAIrB,KAAK,CAAC,IAAN,CAAW,SAJU,CAAvB;EAOA,OAAO,KAAP;AACD,CAdM;;AAAM,OAAA,CAAA,uBAAA,GAAuB,uBAAvB","sourcesContent":["import { makeStyles, mergeClasses } from '@griffel/react';\nimport { tokens } from '@fluentui/react-theme';\nimport type { TableSlots, TableState } from './Table.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\n\nexport const tableClassName = 'fui-Table';\nexport const tableClassNames: SlotClassNames<TableSlots> = {\n root: 'fui-Table',\n};\n\nconst useTableLayoutStyles = makeStyles({\n root: {\n display: 'table',\n verticalAlign: 'middle',\n width: '100%',\n tableLayout: 'fixed',\n },\n});\n\nconst useFlexLayoutStyles = makeStyles({\n root: {\n display: 'block',\n },\n});\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n borderCollapse: 'collapse',\n backgroundColor: tokens.colorSubtleBackground,\n },\n});\n\n/**\n * Apply styling to the Table slots based on the state\n */\nexport const useTableStyles_unstable = (state: TableState): TableState => {\n const styles = useStyles();\n const layoutStyles = {\n table: useTableLayoutStyles(),\n flex: useFlexLayoutStyles(),\n };\n state.root.className = mergeClasses(\n tableClassName,\n styles.root,\n state.noNativeElements ? layoutStyles.flex.root : layoutStyles.table.root,\n state.root.className,\n );\n\n return state;\n};\n"],"sourceRoot":"../src/"}
@@ -1 +1 @@
1
- {"version":3,"sources":["components/TableBody/TableBody.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,cAAA,gBAAA,OAAA,CAAA,gBAAA,CAAA;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,mBAAA,CAAA;;AACA,MAAA,oBAAA,gBAAA,OAAA,CAAA,sBAAA,CAAA;AAIA;;AAEG;;;AACU,OAAA,CAAA,SAAA,gBAAiD,KAAK,CAAC,UAAN,CAAiB,CAAC,KAAD,EAAQ,GAAR,KAAe;EAC5F,MAAM,KAAK,GAAG,cAAA,CAAA,qBAAA,CAAsB,KAAtB,EAA6B,GAA7B,CAAd;EAEA,oBAAA,CAAA,2BAAA,CAA4B,KAA5B;EACA,OAAO,iBAAA,CAAA,wBAAA,CAAyB,KAAzB,CAAP;AACD,CAL6D,CAAjD;AAOb,OAAA,CAAA,SAAA,CAAU,WAAV,GAAwB,WAAxB","sourcesContent":["import * as React from 'react';\nimport { useTableBody_unstable } from './useTableBody';\nimport { renderTableBody_unstable } from './renderTableBody';\nimport { useTableBodyStyles_unstable } from './useTableBodyStyles';\nimport type { TableBodyProps } from './TableBody.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * TableBody component - TODO: add more docs\n */\nexport const TableBody: ForwardRefComponent<TableBodyProps> = React.forwardRef((props, ref) => {\n const state = useTableBody_unstable(props, ref);\n\n useTableBodyStyles_unstable(state);\n return renderTableBody_unstable(state);\n});\n\nTableBody.displayName = 'TableBody';\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableBody/TableBody.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,cAAA,gBAAA,OAAA,CAAA,gBAAA,CAAA;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,mBAAA,CAAA;;AACA,MAAA,oBAAA,gBAAA,OAAA,CAAA,sBAAA,CAAA;AAIA;;AAEG;;;AACU,OAAA,CAAA,SAAA,gBAAiD,KAAK,CAAC,UAAN,CAAiB,CAAC,KAAD,EAAQ,GAAR,KAAe;EAC5F,MAAM,KAAK,GAAG,cAAA,CAAA,qBAAA,CAAsB,KAAtB,EAA6B,GAA7B,CAAd;EAEA,oBAAA,CAAA,2BAAA,CAA4B,KAA5B;EACA,OAAO,iBAAA,CAAA,wBAAA,CAAyB,KAAzB,CAAP;AACD,CAL6D,CAAjD;AAOb,OAAA,CAAA,SAAA,CAAU,WAAV,GAAwB,WAAxB","sourcesContent":["import * as React from 'react';\nimport { useTableBody_unstable } from './useTableBody';\nimport { renderTableBody_unstable } from './renderTableBody';\nimport { useTableBodyStyles_unstable } from './useTableBodyStyles';\nimport type { TableBodyProps } from './TableBody.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * TableBody component - TODO: add more docs\n */\nexport const TableBody: ForwardRefComponent<TableBodyProps> = React.forwardRef((props, ref) => {\n const state = useTableBody_unstable(props, ref);\n\n useTableBodyStyles_unstable(state);\n return renderTableBody_unstable(state);\n});\n\nTableBody.displayName = 'TableBody';\n"],"sourceRoot":"../src/"}
@@ -1 +1 @@
1
- {"version":3,"sources":["components/TableBody/index.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,aAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,mBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,mBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,gBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,sBAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './TableBody';\nexport * from './TableBody.types';\nexport * from './renderTableBody';\nexport * from './useTableBody';\nexport * from './useTableBodyStyles';\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableBody/index.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,aAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,mBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,mBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,gBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,sBAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './TableBody';\nexport * from './TableBody.types';\nexport * from './renderTableBody';\nexport * from './useTableBody';\nexport * from './useTableBodyStyles';\n"],"sourceRoot":"../src/"}
@@ -1 +1 @@
1
- {"version":3,"sources":["components/TableBody/renderTableBody.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;AAGA;;AAEG;;;AACI,MAAM,wBAAwB,GAAI,KAAD,IAA0B;EAChE,MAAM;IAAE,KAAF;IAAS;EAAT,IAAuB,iBAAA,CAAA,QAAA,CAAyB,KAAzB,CAA7B,CADgE,CAGhE;;EACA,OAAO,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,IAAP,EAAW,EAAA,GAAK,SAAS,CAAC;EAAf,CAAX,CAAP;AACD,CALM;;AAAM,OAAA,CAAA,wBAAA,GAAwB,wBAAxB","sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { TableBodyState, TableBodySlots } from './TableBody.types';\n\n/**\n * Render the final JSX of TableBody\n */\nexport const renderTableBody_unstable = (state: TableBodyState) => {\n const { slots, slotProps } = getSlots<TableBodySlots>(state);\n\n // TODO Add additional slots in the appropriate place\n return <slots.root {...slotProps.root} />;\n};\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableBody/renderTableBody.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;AAGA;;AAEG;;;AACI,MAAM,wBAAwB,GAAI,KAAD,IAA0B;EAChE,MAAM;IAAE,KAAF;IAAS;EAAT,IAAuB,iBAAA,CAAA,QAAA,CAAyB,KAAzB,CAA7B,CADgE,CAGhE;;EACA,OAAO,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,IAAP,EAAW,EAAA,GAAK,SAAS,CAAC;EAAf,CAAX,CAAP;AACD,CALM;;AAAM,OAAA,CAAA,wBAAA,GAAwB,wBAAxB","sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { TableBodyState, TableBodySlots } from './TableBody.types';\n\n/**\n * Render the final JSX of TableBody\n */\nexport const renderTableBody_unstable = (state: TableBodyState) => {\n const { slots, slotProps } = getSlots<TableBodySlots>(state);\n\n // TODO Add additional slots in the appropriate place\n return <slots.root {...slotProps.root} />;\n};\n"],"sourceRoot":"../src/"}
@@ -22,7 +22,9 @@ const tableContext_1 = /*#__PURE__*/require("../../contexts/tableContext");
22
22
  const useTableBody_unstable = (props, ref) => {
23
23
  var _a;
24
24
 
25
- const noNativeElements = tableContext_1.useTableContext(ctx => ctx.noNativeElements);
25
+ const {
26
+ noNativeElements
27
+ } = tableContext_1.useTableContext();
26
28
  const rootComponent = ((_a = props.as) !== null && _a !== void 0 ? _a : noNativeElements) ? 'div' : 'tbody';
27
29
  return {
28
30
  components: {
@@ -32,7 +34,8 @@ const useTableBody_unstable = (props, ref) => {
32
34
  ref,
33
35
  role: rootComponent === 'div' ? 'rowgroup' : undefined,
34
36
  ...props
35
- })
37
+ }),
38
+ noNativeElements
36
39
  };
37
40
  };
38
41
 
@@ -1 +1 @@
1
- {"version":3,"sources":["components/TableBody/useTableBody.ts"],"names":[],"mappings":";;;;;;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;;AAEA,MAAA,cAAA,gBAAA,OAAA,CAAA,6BAAA,CAAA;AAEA;;;;;;;;AAQG;;;AACI,MAAM,qBAAqB,GAAG,CAAC,KAAD,EAAwB,GAAxB,KAAuE;;;EAC1G,MAAM,gBAAgB,GAAG,cAAA,CAAA,eAAA,CAAgB,GAAG,IAAI,GAAG,CAAC,gBAA3B,CAAzB;EACA,MAAM,aAAa,GAAG,CAAA,CAAA,EAAA,GAAA,KAAK,CAAC,EAAN,MAAQ,IAAR,IAAQ,EAAA,KAAA,KAAA,CAAR,GAAQ,EAAR,GAAY,gBAAZ,IAA+B,KAA/B,GAAuC,OAA7D;EAEA,OAAO;IACL,UAAU,EAAE;MACV,IAAI,EAAE;IADI,CADP;IAIL,IAAI,EAAE,iBAAA,CAAA,qBAAA,CAAsB,aAAtB,EAAqC;MACzC,GADyC;MAEzC,IAAI,EAAE,aAAa,KAAK,KAAlB,GAA0B,UAA1B,GAAuC,SAFJ;MAGzC,GAAG;IAHsC,CAArC;EAJD,CAAP;AAUD,CAdM;;AAAM,OAAA,CAAA,qBAAA,GAAqB,qBAArB","sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps } from '@fluentui/react-utilities';\nimport type { TableBodyProps, TableBodyState } from './TableBody.types';\nimport { useTableContext } from '../../contexts/tableContext';\n\n/**\n * Create the state required to render TableBody.\n *\n * The returned state can be modified with hooks such as useTableBodyStyles_unstable,\n * before being passed to renderTableBody_unstable.\n *\n * @param props - props from this instance of TableBody\n * @param ref - reference to root HTMLElement of TableBody\n */\nexport const useTableBody_unstable = (props: TableBodyProps, ref: React.Ref<HTMLElement>): TableBodyState => {\n const noNativeElements = useTableContext(ctx => ctx.noNativeElements);\n const rootComponent = props.as ?? noNativeElements ? 'div' : 'tbody';\n\n return {\n components: {\n root: rootComponent,\n },\n root: getNativeElementProps(rootComponent, {\n ref,\n role: rootComponent === 'div' ? 'rowgroup' : undefined,\n ...props,\n }),\n };\n};\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableBody/useTableBody.ts"],"names":[],"mappings":";;;;;;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;;AAEA,MAAA,cAAA,gBAAA,OAAA,CAAA,6BAAA,CAAA;AAEA;;;;;;;;AAQG;;;AACI,MAAM,qBAAqB,GAAG,CAAC,KAAD,EAAwB,GAAxB,KAAuE;;;EAC1G,MAAM;IAAE;EAAF,IAAuB,cAAA,CAAA,eAAA,EAA7B;EACA,MAAM,aAAa,GAAG,CAAA,CAAA,EAAA,GAAA,KAAK,CAAC,EAAN,MAAQ,IAAR,IAAQ,EAAA,KAAA,KAAA,CAAR,GAAQ,EAAR,GAAY,gBAAZ,IAA+B,KAA/B,GAAuC,OAA7D;EAEA,OAAO;IACL,UAAU,EAAE;MACV,IAAI,EAAE;IADI,CADP;IAIL,IAAI,EAAE,iBAAA,CAAA,qBAAA,CAAsB,aAAtB,EAAqC;MACzC,GADyC;MAEzC,IAAI,EAAE,aAAa,KAAK,KAAlB,GAA0B,UAA1B,GAAuC,SAFJ;MAGzC,GAAG;IAHsC,CAArC,CAJD;IASL;EATK,CAAP;AAWD,CAfM;;AAAM,OAAA,CAAA,qBAAA,GAAqB,qBAArB","sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps } from '@fluentui/react-utilities';\nimport type { TableBodyProps, TableBodyState } from './TableBody.types';\nimport { useTableContext } from '../../contexts/tableContext';\n\n/**\n * Create the state required to render TableBody.\n *\n * The returned state can be modified with hooks such as useTableBodyStyles_unstable,\n * before being passed to renderTableBody_unstable.\n *\n * @param props - props from this instance of TableBody\n * @param ref - reference to root HTMLElement of TableBody\n */\nexport const useTableBody_unstable = (props: TableBodyProps, ref: React.Ref<HTMLElement>): TableBodyState => {\n const { noNativeElements } = useTableContext();\n const rootComponent = props.as ?? noNativeElements ? 'div' : 'tbody';\n\n return {\n components: {\n root: rootComponent,\n },\n root: getNativeElementProps(rootComponent, {\n ref,\n role: rootComponent === 'div' ? 'rowgroup' : undefined,\n ...props,\n }),\n noNativeElements,\n };\n};\n"],"sourceRoot":"../src/"}
@@ -7,6 +7,22 @@ exports.useTableBodyStyles_unstable = exports.tableBodyClassNames = exports.tabl
7
7
 
8
8
  const react_1 = /*#__PURE__*/require("@griffel/react");
9
9
 
10
+ const useTableLayoutStyles = /*#__PURE__*/react_1.__styles({
11
+ "root": {
12
+ "mc9l5x": "f1tp1avn"
13
+ }
14
+ }, {
15
+ "d": [".f1tp1avn{display:table-row-group;}"]
16
+ });
17
+
18
+ const useFlexLayoutStyles = /*#__PURE__*/react_1.__styles({
19
+ "root": {
20
+ "mc9l5x": "ftgm304"
21
+ }
22
+ }, {
23
+ "d": [".ftgm304{display:block;}"]
24
+ });
25
+
10
26
  exports.tableBodyClassName = 'fui-TableBody';
11
27
  exports.tableBodyClassNames = {
12
28
  root: 'fui-TableBody'
@@ -16,7 +32,11 @@ exports.tableBodyClassNames = {
16
32
  */
17
33
 
18
34
  const useTableBodyStyles_unstable = state => {
19
- state.root.className = react_1.mergeClasses(exports.tableBodyClassName, state.root.className);
35
+ const layoutStyles = {
36
+ table: useTableLayoutStyles(),
37
+ flex: useFlexLayoutStyles()
38
+ };
39
+ state.root.className = react_1.mergeClasses(exports.tableBodyClassName, state.noNativeElements ? layoutStyles.flex.root : layoutStyles.table.root, state.root.className);
20
40
  return state;
21
41
  };
22
42
 
@@ -1 +1 @@
1
- {"version":3,"sources":["components/TableBody/useTableBodyStyles.ts"],"names":[],"mappings":";;;;;;;AAAA,MAAA,OAAA,gBAAA,OAAA,CAAA,gBAAA,CAAA;;AAIa,OAAA,CAAA,kBAAA,GAAqB,eAArB;AACA,OAAA,CAAA,mBAAA,GAAsD;EACjE,IAAI,EAAE;AAD2D,CAAtD;AAIb;;AAEG;;AACI,MAAM,2BAA2B,GAAI,KAAD,IAA0C;EACnF,KAAK,CAAC,IAAN,CAAW,SAAX,GAAuB,OAAA,CAAA,YAAA,CAAa,OAAA,CAAA,kBAAb,EAAiC,KAAK,CAAC,IAAN,CAAW,SAA5C,CAAvB;EAEA,OAAO,KAAP;AACD,CAJM;;AAAM,OAAA,CAAA,2BAAA,GAA2B,2BAA3B","sourcesContent":["import { mergeClasses } from '@griffel/react';\nimport type { TableBodySlots, TableBodyState } from './TableBody.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\n\nexport const tableBodyClassName = 'fui-TableBody';\nexport const tableBodyClassNames: SlotClassNames<TableBodySlots> = {\n root: 'fui-TableBody',\n};\n\n/**\n * Apply styling to the TableBody slots based on the state\n */\nexport const useTableBodyStyles_unstable = (state: TableBodyState): TableBodyState => {\n state.root.className = mergeClasses(tableBodyClassName, state.root.className);\n\n return state;\n};\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableBody/useTableBodyStyles.ts"],"names":[],"mappings":";;;;;;;AAAA,MAAA,OAAA,gBAAA,OAAA,CAAA,gBAAA,CAAA;;AAIA,MAAM,oBAAoB,gBAAG,OAAA,SAAA;EAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAA7B;;AAMA,MAAM,mBAAmB,gBAAG,OAAA,SAAA;EAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAA5B;;AAMa,OAAA,CAAA,kBAAA,GAAqB,eAArB;AACA,OAAA,CAAA,mBAAA,GAAsD;EACjE,IAAI,EAAE;AAD2D,CAAtD;AAIb;;AAEG;;AACI,MAAM,2BAA2B,GAAI,KAAD,IAA0C;EACnF,MAAM,YAAY,GAAG;IACnB,KAAK,EAAE,oBAAoB,EADR;IAEnB,IAAI,EAAE,mBAAmB;EAFN,CAArB;EAIA,KAAK,CAAC,IAAN,CAAW,SAAX,GAAuB,OAAA,CAAA,YAAA,CACrB,OAAA,CAAA,kBADqB,EAErB,KAAK,CAAC,gBAAN,GAAyB,YAAY,CAAC,IAAb,CAAkB,IAA3C,GAAkD,YAAY,CAAC,KAAb,CAAmB,IAFhD,EAGrB,KAAK,CAAC,IAAN,CAAW,SAHU,CAAvB;EAMA,OAAO,KAAP;AACD,CAZM;;AAAM,OAAA,CAAA,2BAAA,GAA2B,2BAA3B","sourcesContent":["import { mergeClasses, makeStyles } from '@griffel/react';\nimport type { TableBodySlots, TableBodyState } from './TableBody.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\n\nconst useTableLayoutStyles = makeStyles({\n root: {\n display: 'table-row-group',\n },\n});\n\nconst useFlexLayoutStyles = makeStyles({\n root: {\n display: 'block',\n },\n});\n\nexport const tableBodyClassName = 'fui-TableBody';\nexport const tableBodyClassNames: SlotClassNames<TableBodySlots> = {\n root: 'fui-TableBody',\n};\n\n/**\n * Apply styling to the TableBody slots based on the state\n */\nexport const useTableBodyStyles_unstable = (state: TableBodyState): TableBodyState => {\n const layoutStyles = {\n table: useTableLayoutStyles(),\n flex: useFlexLayoutStyles(),\n };\n state.root.className = mergeClasses(\n tableBodyClassName,\n state.noNativeElements ? layoutStyles.flex.root : layoutStyles.table.root,\n state.root.className,\n );\n\n return state;\n};\n"],"sourceRoot":"../src/"}
@@ -1 +1 @@
1
- {"version":3,"sources":["components/TableCell/TableCell.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,cAAA,gBAAA,OAAA,CAAA,gBAAA,CAAA;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,mBAAA,CAAA;;AACA,MAAA,oBAAA,gBAAA,OAAA,CAAA,sBAAA,CAAA;AAIA;;AAEG;;;AACU,OAAA,CAAA,SAAA,gBAAiD,KAAK,CAAC,UAAN,CAAiB,CAAC,KAAD,EAAQ,GAAR,KAAe;EAC5F,MAAM,KAAK,GAAG,cAAA,CAAA,qBAAA,CAAsB,KAAtB,EAA6B,GAA7B,CAAd;EAEA,oBAAA,CAAA,2BAAA,CAA4B,KAA5B;EACA,OAAO,iBAAA,CAAA,wBAAA,CAAyB,KAAzB,CAAP;AACD,CAL6D,CAAjD;AAOb,OAAA,CAAA,SAAA,CAAU,WAAV,GAAwB,WAAxB","sourcesContent":["import * as React from 'react';\nimport { useTableCell_unstable } from './useTableCell';\nimport { renderTableCell_unstable } from './renderTableCell';\nimport { useTableCellStyles_unstable } from './useTableCellStyles';\nimport type { TableCellProps } from './TableCell.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * TableCell component - TODO: add more docs\n */\nexport const TableCell: ForwardRefComponent<TableCellProps> = React.forwardRef((props, ref) => {\n const state = useTableCell_unstable(props, ref);\n\n useTableCellStyles_unstable(state);\n return renderTableCell_unstable(state);\n});\n\nTableCell.displayName = 'TableCell';\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableCell/TableCell.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,cAAA,gBAAA,OAAA,CAAA,gBAAA,CAAA;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,mBAAA,CAAA;;AACA,MAAA,oBAAA,gBAAA,OAAA,CAAA,sBAAA,CAAA;AAIA;;AAEG;;;AACU,OAAA,CAAA,SAAA,gBAAiD,KAAK,CAAC,UAAN,CAAiB,CAAC,KAAD,EAAQ,GAAR,KAAe;EAC5F,MAAM,KAAK,GAAG,cAAA,CAAA,qBAAA,CAAsB,KAAtB,EAA6B,GAA7B,CAAd;EAEA,oBAAA,CAAA,2BAAA,CAA4B,KAA5B;EACA,OAAO,iBAAA,CAAA,wBAAA,CAAyB,KAAzB,CAAP;AACD,CAL6D,CAAjD;AAOb,OAAA,CAAA,SAAA,CAAU,WAAV,GAAwB,WAAxB","sourcesContent":["import * as React from 'react';\nimport { useTableCell_unstable } from './useTableCell';\nimport { renderTableCell_unstable } from './renderTableCell';\nimport { useTableCellStyles_unstable } from './useTableCellStyles';\nimport type { TableCellProps } from './TableCell.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * TableCell component - TODO: add more docs\n */\nexport const TableCell: ForwardRefComponent<TableCellProps> = React.forwardRef((props, ref) => {\n const state = useTableCell_unstable(props, ref);\n\n useTableCellStyles_unstable(state);\n return renderTableCell_unstable(state);\n});\n\nTableCell.displayName = 'TableCell';\n"],"sourceRoot":"../src/"}
@@ -1 +1 @@
1
- {"version":3,"sources":["components/TableCell/index.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,aAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,mBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,mBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,gBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,sBAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './TableCell';\nexport * from './TableCell.types';\nexport * from './renderTableCell';\nexport * from './useTableCell';\nexport * from './useTableCellStyles';\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableCell/index.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,aAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,mBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,mBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,gBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,sBAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './TableCell';\nexport * from './TableCell.types';\nexport * from './renderTableCell';\nexport * from './useTableCell';\nexport * from './useTableCellStyles';\n"],"sourceRoot":"../src/"}
@@ -17,11 +17,9 @@ const renderTableCell_unstable = state => {
17
17
  const {
18
18
  slots,
19
19
  slotProps
20
- } = react_utilities_1.getSlots(state); // TODO Add additional slots in the appropriate place
21
-
20
+ } = react_utilities_1.getSlots(state);
22
21
  return React.createElement(slots.root, { ...slotProps.root
23
- }, slots.media && React.createElement(slots.media, { ...slotProps.media
24
- }), " ", slotProps.root.children);
22
+ });
25
23
  };
26
24
 
27
25
  exports.renderTableCell_unstable = renderTableCell_unstable;
@@ -1 +1 @@
1
- {"version":3,"sources":["components/TableCell/renderTableCell.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;AAGA;;AAEG;;;AACI,MAAM,wBAAwB,GAAI,KAAD,IAA0B;EAChE,MAAM;IAAE,KAAF;IAAS;EAAT,IAAuB,iBAAA,CAAA,QAAA,CAAyB,KAAzB,CAA7B,CADgE,CAGhE;;EACA,OACE,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,IAAP,EAAW,EAAA,GAAK,SAAS,CAAC;EAAf,CAAX,EACG,KAAK,CAAC,KAAN,IAAe,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,KAAP,EAAY,EAAA,GAAK,SAAS,CAAC;EAAf,CAAZ,CADlB,E,GAAA,EACyD,SAAS,CAAC,IAAV,CAAe,QADxE,CADF;AAKD,CATM;;AAAM,OAAA,CAAA,wBAAA,GAAwB,wBAAxB","sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { TableCellState, TableCellSlots } from './TableCell.types';\n\n/**\n * Render the final JSX of TableCell\n */\nexport const renderTableCell_unstable = (state: TableCellState) => {\n const { slots, slotProps } = getSlots<TableCellSlots>(state);\n\n // TODO Add additional slots in the appropriate place\n return (\n <slots.root {...slotProps.root}>\n {slots.media && <slots.media {...slotProps.media} />} {slotProps.root.children}\n </slots.root>\n );\n};\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableCell/renderTableCell.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;AAGA;;AAEG;;;AACI,MAAM,wBAAwB,GAAI,KAAD,IAA0B;EAChE,MAAM;IAAE,KAAF;IAAS;EAAT,IAAuB,iBAAA,CAAA,QAAA,CAAyB,KAAzB,CAA7B;EAEA,OAAO,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,IAAP,EAAW,EAAA,GAAK,SAAS,CAAC;EAAf,CAAX,CAAP;AACD,CAJM;;AAAM,OAAA,CAAA,wBAAA,GAAwB,wBAAxB","sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { TableCellState, TableCellSlots } from './TableCell.types';\n\n/**\n * Render the final JSX of TableCell\n */\nexport const renderTableCell_unstable = (state: TableCellState) => {\n const { slots, slotProps } = getSlots<TableCellSlots>(state);\n\n return <slots.root {...slotProps.root} />;\n};\n"],"sourceRoot":"../src/"}
@@ -22,19 +22,20 @@ const tableContext_1 = /*#__PURE__*/require("../../contexts/tableContext");
22
22
  const useTableCell_unstable = (props, ref) => {
23
23
  var _a;
24
24
 
25
- const noNativeElements = tableContext_1.useTableContext(ctx => ctx.noNativeElements);
25
+ const {
26
+ noNativeElements
27
+ } = tableContext_1.useTableContext();
26
28
  const rootComponent = ((_a = props.as) !== null && _a !== void 0 ? _a : noNativeElements) ? 'div' : 'td';
27
29
  return {
28
30
  components: {
29
- root: rootComponent,
30
- media: 'span'
31
+ root: rootComponent
31
32
  },
32
- media: react_utilities_1.resolveShorthand(props.media),
33
33
  root: react_utilities_1.getNativeElementProps(rootComponent, {
34
34
  ref,
35
35
  role: rootComponent === 'div' ? 'cell' : undefined,
36
36
  ...props
37
- })
37
+ }),
38
+ noNativeElements
38
39
  };
39
40
  };
40
41
 
@@ -1 +1 @@
1
- {"version":3,"sources":["components/TableCell/useTableCell.ts"],"names":[],"mappings":";;;;;;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;;AAEA,MAAA,cAAA,gBAAA,OAAA,CAAA,6BAAA,CAAA;AAEA;;;;;;;;AAQG;;;AACI,MAAM,qBAAqB,GAAG,CAAC,KAAD,EAAwB,GAAxB,KAAuE;;;EAC1G,MAAM,gBAAgB,GAAG,cAAA,CAAA,eAAA,CAAgB,GAAG,IAAI,GAAG,CAAC,gBAA3B,CAAzB;EAEA,MAAM,aAAa,GAAG,CAAA,CAAA,EAAA,GAAA,KAAK,CAAC,EAAN,MAAQ,IAAR,IAAQ,EAAA,KAAA,KAAA,CAAR,GAAQ,EAAR,GAAY,gBAAZ,IAA+B,KAA/B,GAAuC,IAA7D;EAEA,OAAO;IACL,UAAU,EAAE;MACV,IAAI,EAAE,aADI;MAEV,KAAK,EAAE;IAFG,CADP;IAKL,KAAK,EAAE,iBAAA,CAAA,gBAAA,CAAiB,KAAK,CAAC,KAAvB,CALF;IAML,IAAI,EAAE,iBAAA,CAAA,qBAAA,CAAsB,aAAtB,EAAqC;MACzC,GADyC;MAEzC,IAAI,EAAE,aAAa,KAAK,KAAlB,GAA0B,MAA1B,GAAmC,SAFA;MAGzC,GAAG;IAHsC,CAArC;EAND,CAAP;AAYD,CAjBM;;AAAM,OAAA,CAAA,qBAAA,GAAqB,qBAArB","sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps, resolveShorthand } from '@fluentui/react-utilities';\nimport type { TableCellProps, TableCellState } from './TableCell.types';\nimport { useTableContext } from '../../contexts/tableContext';\n\n/**\n * Create the state required to render TableCell.\n *\n * The returned state can be modified with hooks such as useTableCellStyles_unstable,\n * before being passed to renderTableCell_unstable.\n *\n * @param props - props from this instance of TableCell\n * @param ref - reference to root HTMLElement of TableCell\n */\nexport const useTableCell_unstable = (props: TableCellProps, ref: React.Ref<HTMLElement>): TableCellState => {\n const noNativeElements = useTableContext(ctx => ctx.noNativeElements);\n\n const rootComponent = props.as ?? noNativeElements ? 'div' : 'td';\n\n return {\n components: {\n root: rootComponent,\n media: 'span',\n },\n media: resolveShorthand(props.media),\n root: getNativeElementProps(rootComponent, {\n ref,\n role: rootComponent === 'div' ? 'cell' : undefined,\n ...props,\n }),\n };\n};\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableCell/useTableCell.ts"],"names":[],"mappings":";;;;;;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;;AAEA,MAAA,cAAA,gBAAA,OAAA,CAAA,6BAAA,CAAA;AAEA;;;;;;;;AAQG;;;AACI,MAAM,qBAAqB,GAAG,CAAC,KAAD,EAAwB,GAAxB,KAAuE;;;EAC1G,MAAM;IAAE;EAAF,IAAuB,cAAA,CAAA,eAAA,EAA7B;EAEA,MAAM,aAAa,GAAG,CAAA,CAAA,EAAA,GAAA,KAAK,CAAC,EAAN,MAAQ,IAAR,IAAQ,EAAA,KAAA,KAAA,CAAR,GAAQ,EAAR,GAAY,gBAAZ,IAA+B,KAA/B,GAAuC,IAA7D;EAEA,OAAO;IACL,UAAU,EAAE;MACV,IAAI,EAAE;IADI,CADP;IAIL,IAAI,EAAE,iBAAA,CAAA,qBAAA,CAAsB,aAAtB,EAAqC;MACzC,GADyC;MAEzC,IAAI,EAAE,aAAa,KAAK,KAAlB,GAA0B,MAA1B,GAAmC,SAFA;MAGzC,GAAG;IAHsC,CAArC,CAJD;IASL;EATK,CAAP;AAWD,CAhBM;;AAAM,OAAA,CAAA,qBAAA,GAAqB,qBAArB","sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps } from '@fluentui/react-utilities';\nimport type { TableCellProps, TableCellState } from './TableCell.types';\nimport { useTableContext } from '../../contexts/tableContext';\n\n/**\n * Create the state required to render TableCell.\n *\n * The returned state can be modified with hooks such as useTableCellStyles_unstable,\n * before being passed to renderTableCell_unstable.\n *\n * @param props - props from this instance of TableCell\n * @param ref - reference to root HTMLElement of TableCell\n */\nexport const useTableCell_unstable = (props: TableCellProps, ref: React.Ref<HTMLElement>): TableCellState => {\n const { noNativeElements } = useTableContext();\n\n const rootComponent = props.as ?? noNativeElements ? 'div' : 'td';\n\n return {\n components: {\n root: rootComponent,\n },\n root: getNativeElementProps(rootComponent, {\n ref,\n role: rootComponent === 'div' ? 'cell' : undefined,\n ...props,\n }),\n noNativeElements,\n };\n};\n"],"sourceRoot":"../src/"}
@@ -11,33 +11,45 @@ const react_theme_1 = /*#__PURE__*/require("@fluentui/react-theme");
11
11
 
12
12
  exports.tableCellClassName = 'fui-TableCell';
13
13
  exports.tableCellClassNames = {
14
- root: exports.tableCellClassName,
15
- media: 'fui-TableCell__media'
14
+ root: exports.tableCellClassName
16
15
  };
16
+
17
+ const useTableLayoutStyles = /*#__PURE__*/react_1.__styles({
18
+ "root": {
19
+ "mc9l5x": "f15pt5es",
20
+ "ha4doy": "fmrv4ls"
21
+ }
22
+ }, {
23
+ "d": [".f15pt5es{display:table-cell;}", ".fmrv4ls{vertical-align:middle;}"]
24
+ });
25
+
26
+ const useFlexLayoutStyles = /*#__PURE__*/react_1.__styles({
27
+ "root": {
28
+ "mc9l5x": "f22iagw",
29
+ "Bf4jedk": "f10tiqix",
30
+ "Bt984gj": "f122n59",
31
+ "Bh6795r": "fqerorx",
32
+ "Bnnss6s": "f1neuvcm",
33
+ "xawz": "fkjuxzh"
34
+ }
35
+ }, {
36
+ "d": [".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}", ".f10tiqix{min-width:0px;}", ".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}", ".fqerorx{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}", ".f1neuvcm{-webkit-flex-shrink:1;-ms-flex-negative:1;flex-shrink:1;}", ".fkjuxzh{-webkit-flex-basis:0px;-ms-flex-preferred-size:0px;flex-basis:0px;}"]
37
+ });
17
38
  /**
18
39
  * Styles for the root slot
19
40
  */
20
41
 
42
+
21
43
  const useStyles = /*#__PURE__*/react_1.__styles({
22
44
  "root": {
45
+ "qhf8xq": "f10pi13n",
23
46
  "z8tnut": "f1nbblvp",
24
47
  "z189sj": ["f1vdfbxk", "f1f5gg8d"],
25
48
  "Byoj8tv": "f1ov4xf1",
26
- "uwmqm3": ["f1f5gg8d", "f1vdfbxk"],
27
- "mc9l5x": "f22iagw",
28
- "Bt984gj": "f122n59",
29
- "i8kkvl": "fsnqrgy",
30
- "Belr9w4": "fylz90v",
31
- "Bh6795r": "fqerorx",
32
- "Bnnss6s": "f1neuvcm",
33
- "xawz": "fkjuxzh"
34
- },
35
- "media": {
36
- "mc9l5x": "f22iagw",
37
- "Bt984gj": "f122n59"
49
+ "uwmqm3": ["f1f5gg8d", "f1vdfbxk"]
38
50
  }
39
51
  }, {
40
- "d": [".f1nbblvp{padding-top:0px;}", ".f1vdfbxk{padding-right:var(--spacingHorizontalS);}", ".f1f5gg8d{padding-left:var(--spacingHorizontalS);}", ".f1ov4xf1{padding-bottom:0px;}", ".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}", ".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}", ".fsnqrgy{-webkit-column-gap:var(--spacingHorizontalS);column-gap:var(--spacingHorizontalS);}", ".fylz90v{row-gap:var(--spacingHorizontalS);}", ".fqerorx{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}", ".f1neuvcm{-webkit-flex-shrink:1;-ms-flex-negative:1;flex-shrink:1;}", ".fkjuxzh{-webkit-flex-basis:0px;-ms-flex-preferred-size:0px;flex-basis:0px;}"]
52
+ "d": [".f10pi13n{position:relative;}", ".f1nbblvp{padding-top:0px;}", ".f1vdfbxk{padding-right:var(--spacingHorizontalS);}", ".f1f5gg8d{padding-left:var(--spacingHorizontalS);}", ".f1ov4xf1{padding-bottom:0px;}"]
41
53
  });
42
54
  /**
43
55
  * Apply styling to the TableCell slots based on the state
@@ -46,12 +58,11 @@ const useStyles = /*#__PURE__*/react_1.__styles({
46
58
 
47
59
  const useTableCellStyles_unstable = state => {
48
60
  const styles = useStyles();
49
- state.root.className = react_1.mergeClasses(exports.tableCellClassNames.root, styles.root, state.root.className);
50
-
51
- if (state.media) {
52
- state.media.className = react_1.mergeClasses(exports.tableCellClassNames.media, styles.media);
53
- }
54
-
61
+ const layoutStyles = {
62
+ table: useTableLayoutStyles(),
63
+ flex: useFlexLayoutStyles()
64
+ };
65
+ state.root.className = react_1.mergeClasses(exports.tableCellClassNames.root, styles.root, state.noNativeElements ? layoutStyles.flex.root : layoutStyles.table.root, state.root.className);
55
66
  return state;
56
67
  };
57
68
 
@@ -1 +1 @@
1
- {"version":3,"sources":["components/TableCell/useTableCellStyles.ts"],"names":[],"mappings":";;;;;;;AAAA,MAAA,OAAA,gBAAA,OAAA,CAAA,gBAAA,CAAA;;AACA,MAAA,aAAA,gBAAA,OAAA,CAAA,uBAAA,CAAA;;AAIa,OAAA,CAAA,kBAAA,GAAqB,eAArB;AACA,OAAA,CAAA,mBAAA,GAAsD;EACjE,IAAI,EAAE,OAAA,CAAA,kBAD2D;EAEjE,KAAK,EAAE;AAF0D,CAAtD;AAKb;;AAEG;;AACH,MAAM,SAAS,gBAAG,OAAA,SAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAAlB;AAeA;;AAEG;;;AACI,MAAM,2BAA2B,GAAI,KAAD,IAA0C;EACnF,MAAM,MAAM,GAAG,SAAS,EAAxB;EACA,KAAK,CAAC,IAAN,CAAW,SAAX,GAAuB,OAAA,CAAA,YAAA,CAAa,OAAA,CAAA,mBAAA,CAAoB,IAAjC,EAAuC,MAAM,CAAC,IAA9C,EAAoD,KAAK,CAAC,IAAN,CAAW,SAA/D,CAAvB;;EACA,IAAI,KAAK,CAAC,KAAV,EAAiB;IACf,KAAK,CAAC,KAAN,CAAY,SAAZ,GAAwB,OAAA,CAAA,YAAA,CAAa,OAAA,CAAA,mBAAA,CAAoB,KAAjC,EAAwC,MAAM,CAAC,KAA/C,CAAxB;EACD;;EAED,OAAO,KAAP;AACD,CARM;;AAAM,OAAA,CAAA,2BAAA,GAA2B,2BAA3B","sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens } from '@fluentui/react-theme';\nimport type { TableCellSlots, TableCellState } from './TableCell.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\n\nexport const tableCellClassName = 'fui-TableCell';\nexport const tableCellClassNames: SlotClassNames<TableCellSlots> = {\n root: tableCellClassName,\n media: 'fui-TableCell__media',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n ...shorthands.padding('0px', tokens.spacingHorizontalS),\n display: 'flex',\n alignItems: 'center',\n ...shorthands.gap(tokens.spacingHorizontalS),\n ...shorthands.flex(1, 1, '0px'),\n },\n\n media: {\n display: 'flex',\n alignItems: 'center',\n },\n});\n\n/**\n * Apply styling to the TableCell slots based on the state\n */\nexport const useTableCellStyles_unstable = (state: TableCellState): TableCellState => {\n const styles = useStyles();\n state.root.className = mergeClasses(tableCellClassNames.root, styles.root, state.root.className);\n if (state.media) {\n state.media.className = mergeClasses(tableCellClassNames.media, styles.media);\n }\n\n return state;\n};\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableCell/useTableCellStyles.ts"],"names":[],"mappings":";;;;;;;AAAA,MAAA,OAAA,gBAAA,OAAA,CAAA,gBAAA,CAAA;;AACA,MAAA,aAAA,gBAAA,OAAA,CAAA,uBAAA,CAAA;;AAIa,OAAA,CAAA,kBAAA,GAAqB,eAArB;AACA,OAAA,CAAA,mBAAA,GAAsD;EACjE,IAAI,EAAE,OAAA,CAAA;AAD2D,CAAtD;;AAIb,MAAM,oBAAoB,gBAAG,OAAA,SAAA;EAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAA7B;;AAOA,MAAM,mBAAmB,gBAAG,OAAA,SAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAA5B;AASA;;AAEG;;;AACH,MAAM,SAAS,gBAAG,OAAA,SAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAAlB;AAOA;;AAEG;;;AACI,MAAM,2BAA2B,GAAI,KAAD,IAA0C;EACnF,MAAM,MAAM,GAAG,SAAS,EAAxB;EACA,MAAM,YAAY,GAAG;IACnB,KAAK,EAAE,oBAAoB,EADR;IAEnB,IAAI,EAAE,mBAAmB;EAFN,CAArB;EAIA,KAAK,CAAC,IAAN,CAAW,SAAX,GAAuB,OAAA,CAAA,YAAA,CACrB,OAAA,CAAA,mBAAA,CAAoB,IADC,EAErB,MAAM,CAAC,IAFc,EAGrB,KAAK,CAAC,gBAAN,GAAyB,YAAY,CAAC,IAAb,CAAkB,IAA3C,GAAkD,YAAY,CAAC,KAAb,CAAmB,IAHhD,EAIrB,KAAK,CAAC,IAAN,CAAW,SAJU,CAAvB;EAMA,OAAO,KAAP;AACD,CAbM;;AAAM,OAAA,CAAA,2BAAA,GAA2B,2BAA3B","sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens } from '@fluentui/react-theme';\nimport type { TableCellSlots, TableCellState } from './TableCell.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\n\nexport const tableCellClassName = 'fui-TableCell';\nexport const tableCellClassNames: SlotClassNames<TableCellSlots> = {\n root: tableCellClassName,\n};\n\nconst useTableLayoutStyles = makeStyles({\n root: {\n display: 'table-cell',\n verticalAlign: 'middle',\n },\n});\n\nconst useFlexLayoutStyles = makeStyles({\n root: {\n display: 'flex',\n minWidth: '0px',\n alignItems: 'center',\n ...shorthands.flex(1, 1, '0px'),\n },\n});\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n position: 'relative',\n ...shorthands.padding('0px', tokens.spacingHorizontalS),\n },\n});\n\n/**\n * Apply styling to the TableCell slots based on the state\n */\nexport const useTableCellStyles_unstable = (state: TableCellState): TableCellState => {\n const styles = useStyles();\n const layoutStyles = {\n table: useTableLayoutStyles(),\n flex: useFlexLayoutStyles(),\n };\n state.root.className = mergeClasses(\n tableCellClassNames.root,\n styles.root,\n state.noNativeElements ? layoutStyles.flex.root : layoutStyles.table.root,\n state.root.className,\n );\n return state;\n};\n"],"sourceRoot":"../src/"}
@@ -0,0 +1,26 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.TableCellActions = void 0;
7
+
8
+ const React = /*#__PURE__*/require("react");
9
+
10
+ const useTableCellActions_1 = /*#__PURE__*/require("./useTableCellActions");
11
+
12
+ const renderTableCellActions_1 = /*#__PURE__*/require("./renderTableCellActions");
13
+
14
+ const useTableCellActionsStyles_1 = /*#__PURE__*/require("./useTableCellActionsStyles");
15
+ /**
16
+ * TableCellActions component - TODO: add more docs
17
+ */
18
+
19
+
20
+ exports.TableCellActions = /*#__PURE__*/React.forwardRef((props, ref) => {
21
+ const state = useTableCellActions_1.useTableCellActions_unstable(props, ref);
22
+ useTableCellActionsStyles_1.useTableCellActionsStyles_unstable(state);
23
+ return renderTableCellActions_1.renderTableCellActions_unstable(state);
24
+ });
25
+ exports.TableCellActions.displayName = 'TableCellActions';
26
+ //# sourceMappingURL=TableCellActions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableCellActions/TableCellActions.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,qBAAA,gBAAA,OAAA,CAAA,uBAAA,CAAA;;AACA,MAAA,wBAAA,gBAAA,OAAA,CAAA,0BAAA,CAAA;;AACA,MAAA,2BAAA,gBAAA,OAAA,CAAA,6BAAA,CAAA;AAIA;;AAEG;;;AACU,OAAA,CAAA,gBAAA,gBAA+D,KAAK,CAAC,UAAN,CAAiB,CAAC,KAAD,EAAQ,GAAR,KAAe;EAC1G,MAAM,KAAK,GAAG,qBAAA,CAAA,4BAAA,CAA6B,KAA7B,EAAoC,GAApC,CAAd;EAEA,2BAAA,CAAA,kCAAA,CAAmC,KAAnC;EACA,OAAO,wBAAA,CAAA,+BAAA,CAAgC,KAAhC,CAAP;AACD,CAL2E,CAA/D;AAOb,OAAA,CAAA,gBAAA,CAAiB,WAAjB,GAA+B,kBAA/B","sourcesContent":["import * as React from 'react';\nimport { useTableCellActions_unstable } from './useTableCellActions';\nimport { renderTableCellActions_unstable } from './renderTableCellActions';\nimport { useTableCellActionsStyles_unstable } from './useTableCellActionsStyles';\nimport type { TableCellActionsProps } from './TableCellActions.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * TableCellActions component - TODO: add more docs\n */\nexport const TableCellActions: ForwardRefComponent<TableCellActionsProps> = React.forwardRef((props, ref) => {\n const state = useTableCellActions_unstable(props, ref);\n\n useTableCellActionsStyles_unstable(state);\n return renderTableCellActions_unstable(state);\n});\n\nTableCellActions.displayName = 'TableCellActions';\n"],"sourceRoot":"../src/"}
@@ -0,0 +1,6 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ //# sourceMappingURL=TableCellActions.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":"../src/"}
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+
7
+ const tslib_1 = /*#__PURE__*/require("tslib");
8
+
9
+ tslib_1.__exportStar(require("./TableCellActions"), exports);
10
+
11
+ tslib_1.__exportStar(require("./TableCellActions.types"), exports);
12
+
13
+ tslib_1.__exportStar(require("./renderTableCellActions"), exports);
14
+
15
+ tslib_1.__exportStar(require("./useTableCellActions"), exports);
16
+
17
+ tslib_1.__exportStar(require("./useTableCellActionsStyles"), exports);
18
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableCellActions/index.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,oBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,0BAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,0BAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,uBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,6BAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './TableCellActions';\nexport * from './TableCellActions.types';\nexport * from './renderTableCellActions';\nexport * from './useTableCellActions';\nexport * from './useTableCellActionsStyles';\n"],"sourceRoot":"../src/"}
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.renderTableCellActions_unstable = void 0;
7
+
8
+ const React = /*#__PURE__*/require("react");
9
+
10
+ const react_utilities_1 = /*#__PURE__*/require("@fluentui/react-utilities");
11
+ /**
12
+ * Render the final JSX of TableCellActions
13
+ */
14
+
15
+
16
+ const renderTableCellActions_unstable = state => {
17
+ const {
18
+ slots,
19
+ slotProps
20
+ } = react_utilities_1.getSlots(state); // TODO Add additional slots in the appropriate place
21
+
22
+ return React.createElement(slots.root, { ...slotProps.root
23
+ });
24
+ };
25
+
26
+ exports.renderTableCellActions_unstable = renderTableCellActions_unstable;
27
+ //# sourceMappingURL=renderTableCellActions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableCellActions/renderTableCellActions.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;AAGA;;AAEG;;;AACI,MAAM,+BAA+B,GAAI,KAAD,IAAiC;EAC9E,MAAM;IAAE,KAAF;IAAS;EAAT,IAAuB,iBAAA,CAAA,QAAA,CAAgC,KAAhC,CAA7B,CAD8E,CAG9E;;EACA,OAAO,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,IAAP,EAAW,EAAA,GAAK,SAAS,CAAC;EAAf,CAAX,CAAP;AACD,CALM;;AAAM,OAAA,CAAA,+BAAA,GAA+B,+BAA/B","sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { TableCellActionsState, TableCellActionsSlots } from './TableCellActions.types';\n\n/**\n * Render the final JSX of TableCellActions\n */\nexport const renderTableCellActions_unstable = (state: TableCellActionsState) => {\n const { slots, slotProps } = getSlots<TableCellActionsSlots>(state);\n\n // TODO Add additional slots in the appropriate place\n return <slots.root {...slotProps.root} />;\n};\n"],"sourceRoot":"../src/"}
@@ -0,0 +1,38 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.useTableCellActions_unstable = void 0;
7
+
8
+ const react_utilities_1 = /*#__PURE__*/require("@fluentui/react-utilities");
9
+
10
+ const react_tabster_1 = /*#__PURE__*/require("@fluentui/react-tabster");
11
+ /**
12
+ * Create the state required to render TableCellActions.
13
+ *
14
+ * The returned state can be modified with hooks such as useTableCellActionsStyles_unstable,
15
+ * before being passed to renderTableCellActions_unstable.
16
+ *
17
+ * @param props - props from this instance of TableCellActions
18
+ * @param ref - reference to root HTMLElement of TableCellActions
19
+ */
20
+
21
+
22
+ const useTableCellActions_unstable = (props, ref) => {
23
+ var _a;
24
+
25
+ return {
26
+ components: {
27
+ root: 'div'
28
+ },
29
+ root: react_utilities_1.getNativeElementProps('div', {
30
+ ref: react_utilities_1.useMergedRefs(ref, react_tabster_1.useFocusWithin()),
31
+ ...props
32
+ }),
33
+ visible: (_a = props.visible) !== null && _a !== void 0 ? _a : false
34
+ };
35
+ };
36
+
37
+ exports.useTableCellActions_unstable = useTableCellActions_unstable;
38
+ //# sourceMappingURL=useTableCellActions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableCellActions/useTableCellActions.ts"],"names":[],"mappings":";;;;;;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;;AACA,MAAA,eAAA,gBAAA,OAAA,CAAA,yBAAA,CAAA;AAGA;;;;;;;;AAQG;;;AACI,MAAM,4BAA4B,GAAG,CAC1C,KAD0C,EAE1C,GAF0C,KAGjB;;;EACzB,OAAO;IACL,UAAU,EAAE;MACV,IAAI,EAAE;IADI,CADP;IAIL,IAAI,EAAE,iBAAA,CAAA,qBAAA,CAAsB,KAAtB,EAA6B;MACjC,GAAG,EAAE,iBAAA,CAAA,aAAA,CAAc,GAAd,EAAmB,eAAA,CAAA,cAAA,EAAnB,CAD4B;MAEjC,GAAG;IAF8B,CAA7B,CAJD;IAQL,OAAO,EAAE,CAAA,EAAA,GAAA,KAAK,CAAC,OAAN,MAAa,IAAb,IAAa,EAAA,KAAA,KAAA,CAAb,GAAa,EAAb,GAAiB;EARrB,CAAP;AAUD,CAdM;;AAAM,OAAA,CAAA,4BAAA,GAA4B,4BAA5B","sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps, useMergedRefs } from '@fluentui/react-utilities';\nimport { useFocusWithin } from '@fluentui/react-tabster';\nimport type { TableCellActionsProps, TableCellActionsState } from './TableCellActions.types';\n\n/**\n * Create the state required to render TableCellActions.\n *\n * The returned state can be modified with hooks such as useTableCellActionsStyles_unstable,\n * before being passed to renderTableCellActions_unstable.\n *\n * @param props - props from this instance of TableCellActions\n * @param ref - reference to root HTMLElement of TableCellActions\n */\nexport const useTableCellActions_unstable = (\n props: TableCellActionsProps,\n ref: React.Ref<HTMLElement>,\n): TableCellActionsState => {\n return {\n components: {\n root: 'div',\n },\n root: getNativeElementProps('div', {\n ref: useMergedRefs(ref, useFocusWithin()),\n ...props,\n }),\n visible: props.visible ?? false,\n };\n};\n"],"sourceRoot":"../src/"}
@@ -0,0 +1,51 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.useTableCellActionsStyles_unstable = exports.tableCellActionsClassNames = void 0;
7
+
8
+ const react_1 = /*#__PURE__*/require("@griffel/react");
9
+
10
+ const react_tabster_1 = /*#__PURE__*/require("@fluentui/react-tabster");
11
+
12
+ exports.tableCellActionsClassNames = {
13
+ root: 'fui-TableCellActions'
14
+ };
15
+ /**
16
+ * Styles for the root slot
17
+ */
18
+
19
+ const useStyles = /*#__PURE__*/react_1.__styles({
20
+ "root": {
21
+ "qhf8xq": "f1euv43f",
22
+ "j35jbq": ["f10k790i", "f1xynx9j"],
23
+ "Bhzewxz": "f1i1t8d1",
24
+ "Bz10aip": "f188r07x",
25
+ "abs64n": "fk73vx1",
26
+ "Frg6f3": ["fcgxt0o", "f1ujusj6"],
27
+ "Brovlpu": "ftqa4ok",
28
+ "B486eqv": "f2hkw1w",
29
+ "B113ap8": "f1upwfw9"
30
+ },
31
+ "visible": {
32
+ "abs64n": "f5p0z4x"
33
+ }
34
+ }, {
35
+ "d": [".f1euv43f{position:absolute;}", ".f10k790i{right:0px;}", ".f1xynx9j{left:0px;}", ".f1i1t8d1{top:50%;}", ".f188r07x{-webkit-transform:translateY(-50%);-moz-transform:translateY(-50%);-ms-transform:translateY(-50%);transform:translateY(-50%);}", ".fk73vx1{opacity:0;}", ".fcgxt0o{margin-left:auto;}", ".f1ujusj6{margin-right:auto;}", ".f1upwfw9[data-fui-focus-visible]:focus-within{opacity:1;}", ".f5p0z4x{opacity:1;}"],
36
+ "f": [".ftqa4ok:focus{outline-style:none;}"],
37
+ "i": [".f2hkw1w:focus-visible{outline-style:none;}"]
38
+ });
39
+ /**
40
+ * Apply styling to the TableCellActions slots based on the state
41
+ */
42
+
43
+
44
+ const useTableCellActionsStyles_unstable = state => {
45
+ const styles = useStyles();
46
+ state.root.className = react_1.mergeClasses(exports.tableCellActionsClassNames.root, styles.root, state.visible && styles.visible, state.root.className);
47
+ return state;
48
+ };
49
+
50
+ exports.useTableCellActionsStyles_unstable = useTableCellActionsStyles_unstable;
51
+ //# sourceMappingURL=useTableCellActionsStyles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableCellActions/useTableCellActionsStyles.ts"],"names":[],"mappings":";;;;;;;AAAA,MAAA,OAAA,gBAAA,OAAA,CAAA,gBAAA,CAAA;;AAGA,MAAA,eAAA,gBAAA,OAAA,CAAA,yBAAA,CAAA;;AAEa,OAAA,CAAA,0BAAA,GAAoE;EAC/E,IAAI,EAAE;AADyE,CAApE;AAIb;;AAEG;;AACH,MAAM,SAAS,gBAAG,OAAA,SAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;EAAA;AAAA;EAAA;EAAA;EAAA;AAAA,EAAlB;AAsBA;;AAEG;;;AACI,MAAM,kCAAkC,GAAI,KAAD,IAAwD;EACxG,MAAM,MAAM,GAAG,SAAS,EAAxB;EACA,KAAK,CAAC,IAAN,CAAW,SAAX,GAAuB,OAAA,CAAA,YAAA,CACrB,OAAA,CAAA,0BAAA,CAA2B,IADN,EAErB,MAAM,CAAC,IAFc,EAGrB,KAAK,CAAC,OAAN,IAAiB,MAAM,CAAC,OAHH,EAIrB,KAAK,CAAC,IAAN,CAAW,SAJU,CAAvB;EAOA,OAAO,KAAP;AACD,CAVM;;AAAM,OAAA,CAAA,kCAAA,GAAkC,kCAAlC","sourcesContent":["import { makeStyles, mergeClasses } from '@griffel/react';\nimport type { TableCellActionsSlots, TableCellActionsState } from './TableCellActions.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\nimport { createCustomFocusIndicatorStyle } from '@fluentui/react-tabster';\n\nexport const tableCellActionsClassNames: SlotClassNames<TableCellActionsSlots> = {\n root: 'fui-TableCellActions',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n position: 'absolute',\n right: '0px',\n top: '50%',\n transform: 'translateY(-50%)',\n opacity: 0,\n marginLeft: 'auto',\n\n ...createCustomFocusIndicatorStyle(\n {\n opacity: 1,\n },\n { selector: 'focus-within' },\n ),\n },\n\n visible: {\n opacity: 1,\n },\n});\n\n/**\n * Apply styling to the TableCellActions slots based on the state\n */\nexport const useTableCellActionsStyles_unstable = (state: TableCellActionsState): TableCellActionsState => {\n const styles = useStyles();\n state.root.className = mergeClasses(\n tableCellActionsClassNames.root,\n styles.root,\n state.visible && styles.visible,\n state.root.className,\n );\n\n return state;\n};\n"],"sourceRoot":"../src/"}
@@ -0,0 +1,28 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.TableCellLayout = void 0;
7
+
8
+ const React = /*#__PURE__*/require("react");
9
+
10
+ const useTableCellLayout_1 = /*#__PURE__*/require("./useTableCellLayout");
11
+
12
+ const renderTableCellLayout_1 = /*#__PURE__*/require("./renderTableCellLayout");
13
+
14
+ const useTableCellLayoutStyles_1 = /*#__PURE__*/require("./useTableCellLayoutStyles");
15
+
16
+ const useTableCellLayoutContextValues_1 = /*#__PURE__*/require("./useTableCellLayoutContextValues");
17
+ /**
18
+ * TableCellLayout component - TODO: add more docs
19
+ */
20
+
21
+
22
+ exports.TableCellLayout = /*#__PURE__*/React.forwardRef((props, ref) => {
23
+ const state = useTableCellLayout_1.useTableCellLayout_unstable(props, ref);
24
+ useTableCellLayoutStyles_1.useTableCellLayoutStyles_unstable(state);
25
+ return renderTableCellLayout_1.renderTableCellLayout_unstable(state, useTableCellLayoutContextValues_1.useTableCellLayoutContextValues_unstable(state));
26
+ });
27
+ exports.TableCellLayout.displayName = 'TableCellLayout';
28
+ //# sourceMappingURL=TableCellLayout.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["packages/react-components/react-table/src/components/TableCellLayout/TableCellLayout.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,oBAAA,gBAAA,OAAA,CAAA,sBAAA,CAAA;;AACA,MAAA,uBAAA,gBAAA,OAAA,CAAA,yBAAA,CAAA;;AACA,MAAA,0BAAA,gBAAA,OAAA,CAAA,4BAAA,CAAA;;AACA,MAAA,iCAAA,gBAAA,OAAA,CAAA,mCAAA,CAAA;AAIA;;AAEG;;;AACU,OAAA,CAAA,eAAA,gBAA6D,KAAK,CAAC,UAAN,CAAiB,CAAC,KAAD,EAAQ,GAAR,KAAe;EACxG,MAAM,KAAK,GAAG,oBAAA,CAAA,2BAAA,CAA4B,KAA5B,EAAmC,GAAnC,CAAd;EAEA,0BAAA,CAAA,iCAAA,CAAkC,KAAlC;EACA,OAAO,uBAAA,CAAA,8BAAA,CAA+B,KAA/B,EAAsC,iCAAA,CAAA,wCAAA,CAAyC,KAAzC,CAAtC,CAAP;AACD,CALyE,CAA7D;AAOb,OAAA,CAAA,eAAA,CAAgB,WAAhB,GAA8B,iBAA9B","sourcesContent":["import * as React from 'react';\nimport { useTableCellLayout_unstable } from './useTableCellLayout';\nimport { renderTableCellLayout_unstable } from './renderTableCellLayout';\nimport { useTableCellLayoutStyles_unstable } from './useTableCellLayoutStyles';\nimport { useTableCellLayoutContextValues_unstable } from './useTableCellLayoutContextValues';\nimport type { TableCellLayoutProps } from './TableCellLayout.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * TableCellLayout component - TODO: add more docs\n */\nexport const TableCellLayout: ForwardRefComponent<TableCellLayoutProps> = React.forwardRef((props, ref) => {\n const state = useTableCellLayout_unstable(props, ref);\n\n useTableCellLayoutStyles_unstable(state);\n return renderTableCellLayout_unstable(state, useTableCellLayoutContextValues_unstable(state));\n});\n\nTableCellLayout.displayName = 'TableCellLayout';\n"],"sourceRoot":"../src/"}
@@ -0,0 +1,6 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ //# sourceMappingURL=TableCellLayout.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":"../src/"}