@fluentui/react-table 0.0.0-nightly-20221007-1237.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 (319) hide show
  1. package/CHANGELOG.json +354 -0
  2. package/CHANGELOG.md +104 -0
  3. package/LICENSE +15 -0
  4. package/README.md +5 -0
  5. package/Spec.md +63 -0
  6. package/dist/index.d.ts +647 -0
  7. package/lib/Table.js +2 -0
  8. package/lib/Table.js.map +1 -0
  9. package/lib/TableBody.js +2 -0
  10. package/lib/TableBody.js.map +1 -0
  11. package/lib/TableCell.js +2 -0
  12. package/lib/TableCell.js.map +1 -0
  13. package/lib/TableCellActions.js +2 -0
  14. package/lib/TableCellActions.js.map +1 -0
  15. package/lib/TableCellLayout.js +2 -0
  16. package/lib/TableCellLayout.js.map +1 -0
  17. package/lib/TableCellPrimaryLayout.js +2 -0
  18. package/lib/TableCellPrimaryLayout.js.map +1 -0
  19. package/lib/TableHeader.js +2 -0
  20. package/lib/TableHeader.js.map +1 -0
  21. package/lib/TableHeaderCell.js +2 -0
  22. package/lib/TableHeaderCell.js.map +1 -0
  23. package/lib/TableRow.js +2 -0
  24. package/lib/TableRow.js.map +1 -0
  25. package/lib/TableSelectionCell.js +2 -0
  26. package/lib/TableSelectionCell.js.map +1 -0
  27. package/lib/components/Table/Table.js +16 -0
  28. package/lib/components/Table/Table.js.map +1 -0
  29. package/lib/components/Table/Table.types.js +2 -0
  30. package/lib/components/Table/Table.types.js.map +1 -0
  31. package/lib/components/Table/index.js +6 -0
  32. package/lib/components/Table/index.js.map +1 -0
  33. package/lib/components/Table/renderTable.js +18 -0
  34. package/lib/components/Table/renderTable.js.map +1 -0
  35. package/lib/components/Table/useTable.js +30 -0
  36. package/lib/components/Table/useTable.js.map +1 -0
  37. package/lib/components/Table/useTableContextValues.js +17 -0
  38. package/lib/components/Table/useTableContextValues.js.map +1 -0
  39. package/lib/components/Table/useTableStyles.js +53 -0
  40. package/lib/components/Table/useTableStyles.js.map +1 -0
  41. package/lib/components/TableBody/TableBody.js +15 -0
  42. package/lib/components/TableBody/TableBody.js.map +1 -0
  43. package/lib/components/TableBody/TableBody.types.js +2 -0
  44. package/lib/components/TableBody/TableBody.types.js.map +1 -0
  45. package/lib/components/TableBody/index.js +6 -0
  46. package/lib/components/TableBody/index.js.map +1 -0
  47. package/lib/components/TableBody/renderTableBody.js +16 -0
  48. package/lib/components/TableBody/renderTableBody.js.map +1 -0
  49. package/lib/components/TableBody/useTableBody.js +32 -0
  50. package/lib/components/TableBody/useTableBody.js.map +1 -0
  51. package/lib/components/TableBody/useTableBodyStyles.js +35 -0
  52. package/lib/components/TableBody/useTableBodyStyles.js.map +1 -0
  53. package/lib/components/TableCell/TableCell.js +15 -0
  54. package/lib/components/TableCell/TableCell.js.map +1 -0
  55. package/lib/components/TableCell/TableCell.types.js +2 -0
  56. package/lib/components/TableCell/TableCell.types.js.map +1 -0
  57. package/lib/components/TableCell/index.js +6 -0
  58. package/lib/components/TableCell/index.js.map +1 -0
  59. package/lib/components/TableCell/renderTableCell.js +15 -0
  60. package/lib/components/TableCell/renderTableCell.js.map +1 -0
  61. package/lib/components/TableCell/useTableCell.js +32 -0
  62. package/lib/components/TableCell/useTableCell.js.map +1 -0
  63. package/lib/components/TableCell/useTableCellStyles.js +59 -0
  64. package/lib/components/TableCell/useTableCellStyles.js.map +1 -0
  65. package/lib/components/TableCellActions/TableCellActions.js +15 -0
  66. package/lib/components/TableCellActions/TableCellActions.js.map +1 -0
  67. package/lib/components/TableCellActions/TableCellActions.types.js +2 -0
  68. package/lib/components/TableCellActions/TableCellActions.types.js.map +1 -0
  69. package/lib/components/TableCellActions/index.js +6 -0
  70. package/lib/components/TableCellActions/index.js.map +1 -0
  71. package/lib/components/TableCellActions/renderTableCellActions.js +16 -0
  72. package/lib/components/TableCellActions/renderTableCellActions.js.map +1 -0
  73. package/lib/components/TableCellActions/useTableCellActions.js +27 -0
  74. package/lib/components/TableCellActions/useTableCellActions.js.map +1 -0
  75. package/lib/components/TableCellActions/useTableCellActionsStyles.js +40 -0
  76. package/lib/components/TableCellActions/useTableCellActionsStyles.js.map +1 -0
  77. package/lib/components/TableCellLayout/TableCellLayout.js +16 -0
  78. package/lib/components/TableCellLayout/TableCellLayout.js.map +1 -0
  79. package/lib/components/TableCellLayout/TableCellLayout.types.js +2 -0
  80. package/lib/components/TableCellLayout/TableCellLayout.types.js.map +1 -0
  81. package/lib/components/TableCellLayout/index.js +6 -0
  82. package/lib/components/TableCellLayout/index.js.map +1 -0
  83. package/lib/components/TableCellLayout/renderTableCellLayout.js +22 -0
  84. package/lib/components/TableCellLayout/renderTableCellLayout.js.map +1 -0
  85. package/lib/components/TableCellLayout/useTableCellLayout.js +46 -0
  86. package/lib/components/TableCellLayout/useTableCellLayout.js.map +1 -0
  87. package/lib/components/TableCellLayout/useTableCellLayoutContextValues.js +13 -0
  88. package/lib/components/TableCellLayout/useTableCellLayoutContextValues.js.map +1 -0
  89. package/lib/components/TableCellLayout/useTableCellLayoutStyles.js +74 -0
  90. package/lib/components/TableCellLayout/useTableCellLayoutStyles.js.map +1 -0
  91. package/lib/components/TableHeader/TableHeader.js +15 -0
  92. package/lib/components/TableHeader/TableHeader.js.map +1 -0
  93. package/lib/components/TableHeader/TableHeader.types.js +2 -0
  94. package/lib/components/TableHeader/TableHeader.types.js.map +1 -0
  95. package/lib/components/TableHeader/index.js +6 -0
  96. package/lib/components/TableHeader/index.js.map +1 -0
  97. package/lib/components/TableHeader/renderTableHeader.js +15 -0
  98. package/lib/components/TableHeader/renderTableHeader.js.map +1 -0
  99. package/lib/components/TableHeader/useTableHeader.js +39 -0
  100. package/lib/components/TableHeader/useTableHeader.js.map +1 -0
  101. package/lib/components/TableHeader/useTableHeaderStyles.js +41 -0
  102. package/lib/components/TableHeader/useTableHeaderStyles.js.map +1 -0
  103. package/lib/components/TableHeaderCell/TableHeaderCell.js +15 -0
  104. package/lib/components/TableHeaderCell/TableHeaderCell.js.map +1 -0
  105. package/lib/components/TableHeaderCell/TableHeaderCell.types.js +2 -0
  106. package/lib/components/TableHeaderCell/TableHeaderCell.types.js.map +1 -0
  107. package/lib/components/TableHeaderCell/index.js +6 -0
  108. package/lib/components/TableHeaderCell/index.js.map +1 -0
  109. package/lib/components/TableHeaderCell/renderTableHeaderCell.js +17 -0
  110. package/lib/components/TableHeaderCell/renderTableHeaderCell.js.map +1 -0
  111. package/lib/components/TableHeaderCell/useTableHeaderCell.js +62 -0
  112. package/lib/components/TableHeaderCell/useTableHeaderCell.js.map +1 -0
  113. package/lib/components/TableHeaderCell/useTableHeaderCellStyles.js +106 -0
  114. package/lib/components/TableHeaderCell/useTableHeaderCellStyles.js.map +1 -0
  115. package/lib/components/TableRow/TableRow.js +15 -0
  116. package/lib/components/TableRow/TableRow.js.map +1 -0
  117. package/lib/components/TableRow/TableRow.types.js +2 -0
  118. package/lib/components/TableRow/TableRow.types.js.map +1 -0
  119. package/lib/components/TableRow/index.js +6 -0
  120. package/lib/components/TableRow/index.js.map +1 -0
  121. package/lib/components/TableRow/renderTableRow.js +16 -0
  122. package/lib/components/TableRow/renderTableRow.js.map +1 -0
  123. package/lib/components/TableRow/useTableRow.js +34 -0
  124. package/lib/components/TableRow/useTableRow.js.map +1 -0
  125. package/lib/components/TableRow/useTableRowStyles.js +88 -0
  126. package/lib/components/TableRow/useTableRowStyles.js.map +1 -0
  127. package/lib/components/TableSelectionCell/TableSelectionCell.js +15 -0
  128. package/lib/components/TableSelectionCell/TableSelectionCell.js.map +1 -0
  129. package/lib/components/TableSelectionCell/TableSelectionCell.types.js +2 -0
  130. package/lib/components/TableSelectionCell/TableSelectionCell.types.js.map +1 -0
  131. package/lib/components/TableSelectionCell/index.js +6 -0
  132. package/lib/components/TableSelectionCell/index.js.map +1 -0
  133. package/lib/components/TableSelectionCell/renderTableSelectionCell.js +17 -0
  134. package/lib/components/TableSelectionCell/renderTableSelectionCell.js.map +1 -0
  135. package/lib/components/TableSelectionCell/useTableSelectionCell.js +47 -0
  136. package/lib/components/TableSelectionCell/useTableSelectionCell.js.map +1 -0
  137. package/lib/components/TableSelectionCell/useTableSelectionCellStyles.js +81 -0
  138. package/lib/components/TableSelectionCell/useTableSelectionCellStyles.js.map +1 -0
  139. package/lib/contexts/tableContext.js +14 -0
  140. package/lib/contexts/tableContext.js.map +1 -0
  141. package/lib/hooks/index.js +5 -0
  142. package/lib/hooks/index.js.map +1 -0
  143. package/lib/hooks/selectionManager.js +89 -0
  144. package/lib/hooks/selectionManager.js.map +1 -0
  145. package/lib/hooks/types.js +2 -0
  146. package/lib/hooks/types.js.map +1 -0
  147. package/lib/hooks/useSelection.js +74 -0
  148. package/lib/hooks/useSelection.js.map +1 -0
  149. package/lib/hooks/useSort.js +94 -0
  150. package/lib/hooks/useSort.js.map +1 -0
  151. package/lib/hooks/useTable.js +32 -0
  152. package/lib/hooks/useTable.js.map +1 -0
  153. package/lib/index.js +12 -0
  154. package/lib/index.js.map +1 -0
  155. package/lib/navigationModes/cell.js +250 -0
  156. package/lib/navigationModes/cell.js.map +1 -0
  157. package/lib/navigationModes/composite.js +208 -0
  158. package/lib/navigationModes/composite.js.map +1 -0
  159. package/lib/navigationModes/index.js +3 -0
  160. package/lib/navigationModes/index.js.map +1 -0
  161. package/lib/navigationModes/useNavigationMode.js +42 -0
  162. package/lib/navigationModes/useNavigationMode.js.map +1 -0
  163. package/lib-commonjs/Table.js +10 -0
  164. package/lib-commonjs/Table.js.map +1 -0
  165. package/lib-commonjs/TableBody.js +10 -0
  166. package/lib-commonjs/TableBody.js.map +1 -0
  167. package/lib-commonjs/TableCell.js +10 -0
  168. package/lib-commonjs/TableCell.js.map +1 -0
  169. package/lib-commonjs/TableCellActions.js +10 -0
  170. package/lib-commonjs/TableCellActions.js.map +1 -0
  171. package/lib-commonjs/TableCellLayout.js +10 -0
  172. package/lib-commonjs/TableCellLayout.js.map +1 -0
  173. package/lib-commonjs/TableCellPrimaryLayout.js +10 -0
  174. package/lib-commonjs/TableCellPrimaryLayout.js.map +1 -0
  175. package/lib-commonjs/TableHeader.js +10 -0
  176. package/lib-commonjs/TableHeader.js.map +1 -0
  177. package/lib-commonjs/TableHeaderCell.js +10 -0
  178. package/lib-commonjs/TableHeaderCell.js.map +1 -0
  179. package/lib-commonjs/TableRow.js +10 -0
  180. package/lib-commonjs/TableRow.js.map +1 -0
  181. package/lib-commonjs/TableSelectionCell.js +10 -0
  182. package/lib-commonjs/TableSelectionCell.js.map +1 -0
  183. package/lib-commonjs/components/Table/Table.js +28 -0
  184. package/lib-commonjs/components/Table/Table.js.map +1 -0
  185. package/lib-commonjs/components/Table/Table.types.js +6 -0
  186. package/lib-commonjs/components/Table/Table.types.js.map +1 -0
  187. package/lib-commonjs/components/Table/index.js +18 -0
  188. package/lib-commonjs/components/Table/index.js.map +1 -0
  189. package/lib-commonjs/components/Table/renderTable.js +30 -0
  190. package/lib-commonjs/components/Table/renderTable.js.map +1 -0
  191. package/lib-commonjs/components/Table/useTable.js +40 -0
  192. package/lib-commonjs/components/Table/useTable.js.map +1 -0
  193. package/lib-commonjs/components/Table/useTableContextValues.js +27 -0
  194. package/lib-commonjs/components/Table/useTableContextValues.js.map +1 -0
  195. package/lib-commonjs/components/Table/useTableStyles.js +64 -0
  196. package/lib-commonjs/components/Table/useTableStyles.js.map +1 -0
  197. package/lib-commonjs/components/TableBody/TableBody.js +26 -0
  198. package/lib-commonjs/components/TableBody/TableBody.js.map +1 -0
  199. package/lib-commonjs/components/TableBody/TableBody.types.js +6 -0
  200. package/lib-commonjs/components/TableBody/TableBody.types.js.map +1 -0
  201. package/lib-commonjs/components/TableBody/index.js +18 -0
  202. package/lib-commonjs/components/TableBody/index.js.map +1 -0
  203. package/lib-commonjs/components/TableBody/renderTableBody.js +27 -0
  204. package/lib-commonjs/components/TableBody/renderTableBody.js.map +1 -0
  205. package/lib-commonjs/components/TableBody/useTableBody.js +43 -0
  206. package/lib-commonjs/components/TableBody/useTableBody.js.map +1 -0
  207. package/lib-commonjs/components/TableBody/useTableBodyStyles.js +44 -0
  208. package/lib-commonjs/components/TableBody/useTableBodyStyles.js.map +1 -0
  209. package/lib-commonjs/components/TableCell/TableCell.js +26 -0
  210. package/lib-commonjs/components/TableCell/TableCell.js.map +1 -0
  211. package/lib-commonjs/components/TableCell/TableCell.types.js +6 -0
  212. package/lib-commonjs/components/TableCell/TableCell.types.js.map +1 -0
  213. package/lib-commonjs/components/TableCell/index.js +18 -0
  214. package/lib-commonjs/components/TableCell/index.js.map +1 -0
  215. package/lib-commonjs/components/TableCell/renderTableCell.js +26 -0
  216. package/lib-commonjs/components/TableCell/renderTableCell.js.map +1 -0
  217. package/lib-commonjs/components/TableCell/useTableCell.js +43 -0
  218. package/lib-commonjs/components/TableCell/useTableCell.js.map +1 -0
  219. package/lib-commonjs/components/TableCell/useTableCellStyles.js +70 -0
  220. package/lib-commonjs/components/TableCell/useTableCellStyles.js.map +1 -0
  221. package/lib-commonjs/components/TableCellActions/TableCellActions.js +26 -0
  222. package/lib-commonjs/components/TableCellActions/TableCellActions.js.map +1 -0
  223. package/lib-commonjs/components/TableCellActions/TableCellActions.types.js +6 -0
  224. package/lib-commonjs/components/TableCellActions/TableCellActions.types.js.map +1 -0
  225. package/lib-commonjs/components/TableCellActions/index.js +18 -0
  226. package/lib-commonjs/components/TableCellActions/index.js.map +1 -0
  227. package/lib-commonjs/components/TableCellActions/renderTableCellActions.js +27 -0
  228. package/lib-commonjs/components/TableCellActions/renderTableCellActions.js.map +1 -0
  229. package/lib-commonjs/components/TableCellActions/useTableCellActions.js +38 -0
  230. package/lib-commonjs/components/TableCellActions/useTableCellActions.js.map +1 -0
  231. package/lib-commonjs/components/TableCellActions/useTableCellActionsStyles.js +51 -0
  232. package/lib-commonjs/components/TableCellActions/useTableCellActionsStyles.js.map +1 -0
  233. package/lib-commonjs/components/TableCellLayout/TableCellLayout.js +28 -0
  234. package/lib-commonjs/components/TableCellLayout/TableCellLayout.js.map +1 -0
  235. package/lib-commonjs/components/TableCellLayout/TableCellLayout.types.js +6 -0
  236. package/lib-commonjs/components/TableCellLayout/TableCellLayout.types.js.map +1 -0
  237. package/lib-commonjs/components/TableCellLayout/index.js +18 -0
  238. package/lib-commonjs/components/TableCellLayout/index.js.map +1 -0
  239. package/lib-commonjs/components/TableCellLayout/renderTableCellLayout.js +34 -0
  240. package/lib-commonjs/components/TableCellLayout/renderTableCellLayout.js.map +1 -0
  241. package/lib-commonjs/components/TableCellLayout/useTableCellLayout.js +57 -0
  242. package/lib-commonjs/components/TableCellLayout/useTableCellLayout.js.map +1 -0
  243. package/lib-commonjs/components/TableCellLayout/useTableCellLayoutContextValues.js +23 -0
  244. package/lib-commonjs/components/TableCellLayout/useTableCellLayoutContextValues.js.map +1 -0
  245. package/lib-commonjs/components/TableCellLayout/useTableCellLayoutStyles.js +85 -0
  246. package/lib-commonjs/components/TableCellLayout/useTableCellLayoutStyles.js.map +1 -0
  247. package/lib-commonjs/components/TableHeader/TableHeader.js +26 -0
  248. package/lib-commonjs/components/TableHeader/TableHeader.js.map +1 -0
  249. package/lib-commonjs/components/TableHeader/TableHeader.types.js +6 -0
  250. package/lib-commonjs/components/TableHeader/TableHeader.types.js.map +1 -0
  251. package/lib-commonjs/components/TableHeader/index.js +18 -0
  252. package/lib-commonjs/components/TableHeader/index.js.map +1 -0
  253. package/lib-commonjs/components/TableHeader/renderTableHeader.js +26 -0
  254. package/lib-commonjs/components/TableHeader/renderTableHeader.js.map +1 -0
  255. package/lib-commonjs/components/TableHeader/useTableHeader.js +51 -0
  256. package/lib-commonjs/components/TableHeader/useTableHeader.js.map +1 -0
  257. package/lib-commonjs/components/TableHeader/useTableHeaderStyles.js +51 -0
  258. package/lib-commonjs/components/TableHeader/useTableHeaderStyles.js.map +1 -0
  259. package/lib-commonjs/components/TableHeaderCell/TableHeaderCell.js +26 -0
  260. package/lib-commonjs/components/TableHeaderCell/TableHeaderCell.js.map +1 -0
  261. package/lib-commonjs/components/TableHeaderCell/TableHeaderCell.types.js +6 -0
  262. package/lib-commonjs/components/TableHeaderCell/TableHeaderCell.types.js.map +1 -0
  263. package/lib-commonjs/components/TableHeaderCell/index.js +18 -0
  264. package/lib-commonjs/components/TableHeaderCell/index.js.map +1 -0
  265. package/lib-commonjs/components/TableHeaderCell/renderTableHeaderCell.js +28 -0
  266. package/lib-commonjs/components/TableHeaderCell/renderTableHeaderCell.js.map +1 -0
  267. package/lib-commonjs/components/TableHeaderCell/useTableHeaderCell.js +76 -0
  268. package/lib-commonjs/components/TableHeaderCell/useTableHeaderCell.js.map +1 -0
  269. package/lib-commonjs/components/TableHeaderCell/useTableHeaderCellStyles.js +117 -0
  270. package/lib-commonjs/components/TableHeaderCell/useTableHeaderCellStyles.js.map +1 -0
  271. package/lib-commonjs/components/TableRow/TableRow.js +26 -0
  272. package/lib-commonjs/components/TableRow/TableRow.js.map +1 -0
  273. package/lib-commonjs/components/TableRow/TableRow.types.js +6 -0
  274. package/lib-commonjs/components/TableRow/TableRow.types.js.map +1 -0
  275. package/lib-commonjs/components/TableRow/index.js +18 -0
  276. package/lib-commonjs/components/TableRow/index.js.map +1 -0
  277. package/lib-commonjs/components/TableRow/renderTableRow.js +27 -0
  278. package/lib-commonjs/components/TableRow/renderTableRow.js.map +1 -0
  279. package/lib-commonjs/components/TableRow/useTableRow.js +45 -0
  280. package/lib-commonjs/components/TableRow/useTableRow.js.map +1 -0
  281. package/lib-commonjs/components/TableRow/useTableRowStyles.js +100 -0
  282. package/lib-commonjs/components/TableRow/useTableRowStyles.js.map +1 -0
  283. package/lib-commonjs/components/TableSelectionCell/TableSelectionCell.js +26 -0
  284. package/lib-commonjs/components/TableSelectionCell/TableSelectionCell.js.map +1 -0
  285. package/lib-commonjs/components/TableSelectionCell/TableSelectionCell.types.js +6 -0
  286. package/lib-commonjs/components/TableSelectionCell/TableSelectionCell.types.js.map +1 -0
  287. package/lib-commonjs/components/TableSelectionCell/index.js +18 -0
  288. package/lib-commonjs/components/TableSelectionCell/index.js.map +1 -0
  289. package/lib-commonjs/components/TableSelectionCell/renderTableSelectionCell.js +28 -0
  290. package/lib-commonjs/components/TableSelectionCell/renderTableSelectionCell.js.map +1 -0
  291. package/lib-commonjs/components/TableSelectionCell/useTableSelectionCell.js +62 -0
  292. package/lib-commonjs/components/TableSelectionCell/useTableSelectionCell.js.map +1 -0
  293. package/lib-commonjs/components/TableSelectionCell/useTableSelectionCellStyles.js +91 -0
  294. package/lib-commonjs/components/TableSelectionCell/useTableSelectionCellStyles.js.map +1 -0
  295. package/lib-commonjs/contexts/tableContext.js +25 -0
  296. package/lib-commonjs/contexts/tableContext.js.map +1 -0
  297. package/lib-commonjs/hooks/index.js +16 -0
  298. package/lib-commonjs/hooks/index.js.map +1 -0
  299. package/lib-commonjs/hooks/selectionManager.js +98 -0
  300. package/lib-commonjs/hooks/selectionManager.js.map +1 -0
  301. package/lib-commonjs/hooks/types.js +6 -0
  302. package/lib-commonjs/hooks/types.js.map +1 -0
  303. package/lib-commonjs/hooks/useSelection.js +89 -0
  304. package/lib-commonjs/hooks/useSelection.js.map +1 -0
  305. package/lib-commonjs/hooks/useSort.js +107 -0
  306. package/lib-commonjs/hooks/useSort.js.map +1 -0
  307. package/lib-commonjs/hooks/useTable.js +42 -0
  308. package/lib-commonjs/hooks/useTable.js.map +1 -0
  309. package/lib-commonjs/index.js +377 -0
  310. package/lib-commonjs/index.js.map +1 -0
  311. package/lib-commonjs/navigationModes/cell.js +259 -0
  312. package/lib-commonjs/navigationModes/cell.js.map +1 -0
  313. package/lib-commonjs/navigationModes/composite.js +217 -0
  314. package/lib-commonjs/navigationModes/composite.js.map +1 -0
  315. package/lib-commonjs/navigationModes/index.js +16 -0
  316. package/lib-commonjs/navigationModes/index.js.map +1 -0
  317. package/lib-commonjs/navigationModes/useNavigationMode.js +55 -0
  318. package/lib-commonjs/navigationModes/useNavigationMode.js.map +1 -0
  319. package/package.json +50 -0
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableHeaderCell/useTableHeaderCell.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAZ,MAAuB,OAAvB;AACA,SAAS,qBAAT,EAAgC,gBAAhC,QAAwD,2BAAxD;AACA,SAAS,cAAT,EAAyB,gBAAzB,QAAiD,uBAAjD;AAEA,SAAS,eAAT,QAAgC,6BAAhC;AACA,SAAS,sBAAT,QAAuC,sBAAvC;AAEA,MAAM,SAAS,GAAG;EAChB,SAAS,eAAE,KAAA,CAAA,aAAA,CAAC,cAAD,EAAe,IAAf,CADK;EAEhB,UAAU,eAAE,KAAA,CAAA,aAAA,CAAC,gBAAD,EAAiB,IAAjB;AAFI,CAAlB;AAKA;;;;;;;;AAQG;;AACH,OAAO,MAAM,2BAA2B,GAAG,CACzC,KADyC,EAEzC,GAFyC,KAGjB;;;EACxB,MAAM;IAAE,gBAAF;IAAoB;EAApB,IAAiC,eAAe,EAAtD;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;EACA,OAAO;IACL,UAAU,EAAE;MACV,IAAI,EAAE,aADI;MAEV,MAAM,EAAE,QAFE;MAGV,QAAQ,EAAE;IAHA,CADP;IAML,IAAI,EAAE,qBAAqB,CAAC,aAAD,EAAgB;MACzC,GADyC;MAEzC,IAAI,EAAE,aAAa,KAAK,KAAlB,GAA0B,cAA1B,GAA2C,SAFR;MAGzC,aAAa,KAAK,CAAC,aAHsB;MAIzC,GAAG;IAJsC,CAAhB,CANtB;IAYL,QAAQ,EAAE,gBAAgB,CAAC,KAAK,CAAC,QAAP,EAAiB;MACzC,QAAQ,EAAE,CAAC,CAAC,KAAK,CAAC,aADuB;MAEzC,YAAY,EAAE;QAAE,QAAQ,EAAE,KAAK,CAAC,aAAN,GAAsB,SAAS,CAAC,KAAK,CAAC,aAAP,CAA/B,GAAuD;MAAnE;IAF2B,CAAjB,CAZrB;IAgBL,MAAM,EAAE,sBAAsB,CAAC,KAAK,CAAC,MAAP,EAAe;MAC3C,QAAQ,EAAE,IADiC;MAE3C,YAAY,EAAE;QACZ,IAAI,EAAE,cADM;QAEZ,QAAQ,EAAE,CAAC,CAFC;QAGZ,IAAI,EAAE,QAHM;QAIZ,IAAI,QAAQ,IAAI;UACd,IAAI,EAAE,SADQ;UAEd,QAAQ,EAAE;QAFI,CAAhB;MAJY;IAF6B,CAAf,CAhBzB;IA4BL,QA5BK;IA6BL;EA7BK,CAAP;AA+BD,CAtCM","sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps, resolveShorthand } from '@fluentui/react-utilities';\nimport { ArrowUpRegular, ArrowDownRegular } from '@fluentui/react-icons';\nimport type { TableHeaderCellProps, TableHeaderCellState } from './TableHeaderCell.types';\nimport { useTableContext } from '../../contexts/tableContext';\nimport { useARIAButtonShorthand } from '@fluentui/react-aria';\n\nconst sortIcons = {\n ascending: <ArrowUpRegular />,\n descending: <ArrowDownRegular />,\n};\n\n/**\n * Create the state required to render TableHeaderCell.\n *\n * The returned state can be modified with hooks such as useTableHeaderCellStyles_unstable,\n * before being passed to renderTableHeaderCell_unstable.\n *\n * @param props - props from this instance of TableHeaderCell\n * @param ref - reference to root HTMLElement of TableHeaderCell\n */\nexport const useTableHeaderCell_unstable = (\n props: TableHeaderCellProps,\n ref: React.Ref<HTMLElement>,\n): TableHeaderCellState => {\n const { noNativeElements, sortable } = useTableContext();\n\n const rootComponent = props.as ?? noNativeElements ? 'div' : 'th';\n return {\n components: {\n root: rootComponent,\n button: 'button',\n sortIcon: 'span',\n },\n root: getNativeElementProps(rootComponent, {\n ref,\n role: rootComponent === 'div' ? 'columnheader' : undefined,\n 'aria-sort': props.sortDirection,\n ...props,\n }),\n sortIcon: resolveShorthand(props.sortIcon, {\n required: !!props.sortDirection,\n defaultProps: { children: props.sortDirection ? sortIcons[props.sortDirection] : undefined },\n }),\n button: useARIAButtonShorthand(props.button, {\n required: true,\n defaultProps: {\n role: 'presentation',\n tabIndex: -1,\n type: 'button',\n ...(sortable && {\n role: undefined,\n tabIndex: undefined,\n }),\n },\n }),\n sortable,\n noNativeElements,\n };\n};\n"],"sourceRoot":""}
@@ -0,0 +1,106 @@
1
+ import { __styles, mergeClasses, shorthands } from '@griffel/react';
2
+ import { tokens } from '@fluentui/react-theme';
3
+ export const tableHeaderCellClassName = 'fui-TableHeaderCell';
4
+ export const tableHeaderCellClassNames = {
5
+ root: 'fui-TableHeaderCell',
6
+ button: 'fui-TableHeaderCell__button',
7
+ sortIcon: 'fui-TableHeaderCell__sortIcon'
8
+ };
9
+
10
+ const useTableLayoutStyles = /*#__PURE__*/__styles({
11
+ "root": {
12
+ "mc9l5x": "f15pt5es",
13
+ "ha4doy": "fmrv4ls"
14
+ }
15
+ }, {
16
+ "d": [".f15pt5es{display:table-cell;}", ".fmrv4ls{vertical-align:middle;}"]
17
+ });
18
+
19
+ const useFlexLayoutStyles = /*#__PURE__*/__styles({
20
+ "root": {
21
+ "mc9l5x": "f22iagw",
22
+ "Bh6795r": "fqerorx",
23
+ "Bnnss6s": "f1neuvcm",
24
+ "xawz": "fkjuxzh",
25
+ "Bf4jedk": "f10tiqix"
26
+ }
27
+ }, {
28
+ "d": [".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}", ".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;}", ".f10tiqix{min-width:0px;}"]
29
+ });
30
+ /**
31
+ * Styles for the root slot
32
+ */
33
+
34
+
35
+ const useStyles = /*#__PURE__*/__styles({
36
+ "root": {
37
+ "z8tnut": "f1nbblvp",
38
+ "z189sj": ["f1vdfbxk", "f1f5gg8d"],
39
+ "Byoj8tv": "f1ov4xf1",
40
+ "uwmqm3": ["f1f5gg8d", "f1vdfbxk"]
41
+ },
42
+ "resetButton": {
43
+ "B3rzk8w": "fq6nmtn",
44
+ "B7ck84d": "f1e4lqlz",
45
+ "De3pzq": "f1u2r49w",
46
+ "sj55zd": "f1ym3bx4",
47
+ "Bahqtrf": "f1mo0ibp",
48
+ "Be2twd7": "fjoy568",
49
+ "Bg96gwp": "fytdu2e",
50
+ "B68tc82": "f1mtd64y",
51
+ "Bmxbyg5": "f1y7q3j9",
52
+ "z8tnut": "f1g0x7ka",
53
+ "z189sj": ["fhxju0i", "f1cnd47f"],
54
+ "Byoj8tv": "f1qch9an",
55
+ "uwmqm3": ["f1cnd47f", "fhxju0i"],
56
+ "icvyot": "f1ern45e",
57
+ "vrafjx": ["f1n71otn", "f1deefiw"],
58
+ "oivjwe": "f1h8hb77",
59
+ "wvpqe5": ["f1deefiw", "f1n71otn"],
60
+ "Bv0vk6g": "f37px4s",
61
+ "fsow6f": "fgusgyc"
62
+ },
63
+ "button": {
64
+ "qhf8xq": "f10pi13n",
65
+ "a9b677": "fly5x3f",
66
+ "mc9l5x": "f22iagw",
67
+ "Bh6795r": "fqerorx",
68
+ "Bqenvij": "f1l02sjl",
69
+ "Bt984gj": "f122n59",
70
+ "i8kkvl": "fsnqrgy",
71
+ "Belr9w4": "fylz90v",
72
+ "sshi5w": "f5pgtk9",
73
+ "Bnnss6s": "f1neuvcm",
74
+ "xawz": "fkjuxzh"
75
+ },
76
+ "sortable": {
77
+ "Bceei9c": "f1k6fduh"
78
+ },
79
+ "sortIcon": {
80
+ "mc9l5x": "f22iagw",
81
+ "Bt984gj": "f122n59"
82
+ }
83
+ }, {
84
+ "d": [".f1nbblvp{padding-top:0px;}", ".f1vdfbxk{padding-right:var(--spacingHorizontalS);}", ".f1f5gg8d{padding-left:var(--spacingHorizontalS);}", ".f1ov4xf1{padding-bottom:0px;}", ".fq6nmtn{resize:horizontal;}", ".f1e4lqlz{box-sizing:content-box;}", ".f1u2r49w{background-color:inherit;}", ".f1ym3bx4{color:inherit;}", ".f1mo0ibp{font-family:inherit;}", ".fjoy568{font-size:inherit;}", ".fytdu2e{line-height:normal;}", ".f1mtd64y{overflow-x:visible;}", ".f1y7q3j9{overflow-y:visible;}", ".f1g0x7ka{padding-top:0;}", ".fhxju0i{padding-right:0;}", ".f1cnd47f{padding-left:0;}", ".f1qch9an{padding-bottom:0;}", ".f1ern45e{border-top-style:none;}", ".f1n71otn{border-right-style:none;}", ".f1deefiw{border-left-style:none;}", ".f1h8hb77{border-bottom-style:none;}", ".f37px4s{-webkit-appearance:button;}", ".fgusgyc{text-align:unset;}", ".f10pi13n{position:relative;}", ".fly5x3f{width:100%;}", ".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}", ".fqerorx{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}", ".f1l02sjl{height:100%;}", ".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);}", ".f5pgtk9{min-height:44px;}", ".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;}", ".f1k6fduh{cursor:pointer;}"]
85
+ });
86
+ /**
87
+ * Apply styling to the TableHeaderCell slots based on the state
88
+ */
89
+
90
+
91
+ export const useTableHeaderCellStyles_unstable = state => {
92
+ const styles = useStyles();
93
+ const layoutStyles = {
94
+ table: useTableLayoutStyles(),
95
+ flex: useFlexLayoutStyles()
96
+ };
97
+ state.root.className = mergeClasses(tableHeaderCellClassNames.root, styles.root, state.noNativeElements ? layoutStyles.flex.root : layoutStyles.table.root, state.root.className);
98
+ state.button.className = mergeClasses(tableHeaderCellClassNames.button, styles.resetButton, styles.button, state.sortable && styles.sortable, state.button.className);
99
+
100
+ if (state.sortIcon) {
101
+ state.sortIcon.className = mergeClasses(tableHeaderCellClassNames.sortIcon, styles.sortIcon, state.sortIcon.className);
102
+ }
103
+
104
+ return state;
105
+ };
106
+ //# sourceMappingURL=useTableHeaderCellStyles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableHeaderCell/useTableHeaderCellStyles.ts"],"names":[],"mappings":"AAAA,mBAAqB,YAArB,EAAmC,UAAnC,QAAqD,gBAArD;AACA,SAAS,MAAT,QAAuB,uBAAvB;AAIA,OAAO,MAAM,wBAAwB,GAAG,qBAAjC;AACP,OAAO,MAAM,yBAAyB,GAAyC;EAC7E,IAAI,EAAE,qBADuE;EAE7E,MAAM,EAAE,6BAFqE;EAG7E,QAAQ,EAAE;AAHmE,CAAxE;;AAMP,MAAM,oBAAoB,gBAAG;EAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAA7B;;AAOA,MAAM,mBAAmB,gBAAG;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAA5B;AAQA;;AAEG;;;AACH,MAAM,SAAS,gBAAG;EAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;EAAA;EAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAAlB;AAwCA;;AAEG;;;AACH,OAAO,MAAM,iCAAiC,GAAI,KAAD,IAAsD;EACrG,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,YAAY,CACjC,yBAAyB,CAAC,IADO,EAEjC,MAAM,CAAC,IAF0B,EAGjC,KAAK,CAAC,gBAAN,GAAyB,YAAY,CAAC,IAAb,CAAkB,IAA3C,GAAkD,YAAY,CAAC,KAAb,CAAmB,IAHpC,EAIjC,KAAK,CAAC,IAAN,CAAW,SAJsB,CAAnC;EAMA,KAAK,CAAC,MAAN,CAAa,SAAb,GAAyB,YAAY,CACnC,yBAAyB,CAAC,MADS,EAEnC,MAAM,CAAC,WAF4B,EAGnC,MAAM,CAAC,MAH4B,EAInC,KAAK,CAAC,QAAN,IAAkB,MAAM,CAAC,QAJU,EAKnC,KAAK,CAAC,MAAN,CAAa,SALsB,CAArC;;EAQA,IAAI,KAAK,CAAC,QAAV,EAAoB;IAClB,KAAK,CAAC,QAAN,CAAe,SAAf,GAA2B,YAAY,CACrC,yBAAyB,CAAC,QADW,EAErC,MAAM,CAAC,QAF8B,EAGrC,KAAK,CAAC,QAAN,CAAe,SAHsB,CAAvC;EAKD;;EAED,OAAO,KAAP;AACD,CA7BM","sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens } from '@fluentui/react-theme';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\nimport type { TableHeaderCellSlots, TableHeaderCellState } from './TableHeaderCell.types';\n\nexport const tableHeaderCellClassName = 'fui-TableHeaderCell';\nexport const tableHeaderCellClassNames: SlotClassNames<TableHeaderCellSlots> = {\n root: 'fui-TableHeaderCell',\n button: 'fui-TableHeaderCell__button',\n sortIcon: 'fui-TableHeaderCell__sortIcon',\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 ...shorthands.flex(1, 1, '0px'),\n minWidth: '0px',\n },\n});\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n ...shorthands.padding('0px', tokens.spacingHorizontalS),\n },\n\n resetButton: {\n resize: 'horizontal',\n boxSizing: 'content-box',\n backgroundColor: 'inherit',\n color: 'inherit',\n fontFamily: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'normal',\n ...shorthands.overflow('visible'),\n ...shorthands.padding(0),\n ...shorthands.borderStyle('none'),\n WebkitAppearance: 'button',\n textAlign: 'unset',\n },\n button: {\n position: 'relative',\n width: '100%',\n display: 'flex',\n flexGrow: 1,\n height: '100%',\n alignItems: 'center',\n ...shorthands.gap(tokens.spacingHorizontalS),\n minHeight: '44px',\n ...shorthands.flex(1, 1, '0px'),\n },\n sortable: {\n cursor: 'pointer',\n },\n\n sortIcon: {\n display: 'flex',\n alignItems: 'center',\n },\n});\n\n/**\n * Apply styling to the TableHeaderCell slots based on the state\n */\nexport const useTableHeaderCellStyles_unstable = (state: TableHeaderCellState): TableHeaderCellState => {\n const styles = useStyles();\n const layoutStyles = {\n table: useTableLayoutStyles(),\n flex: useFlexLayoutStyles(),\n };\n state.root.className = mergeClasses(\n tableHeaderCellClassNames.root,\n styles.root,\n state.noNativeElements ? layoutStyles.flex.root : layoutStyles.table.root,\n state.root.className,\n );\n state.button.className = mergeClasses(\n tableHeaderCellClassNames.button,\n styles.resetButton,\n styles.button,\n state.sortable && styles.sortable,\n state.button.className,\n );\n\n if (state.sortIcon) {\n state.sortIcon.className = mergeClasses(\n tableHeaderCellClassNames.sortIcon,\n styles.sortIcon,\n state.sortIcon.className,\n );\n }\n\n return state;\n};\n"],"sourceRoot":""}
@@ -0,0 +1,15 @@
1
+ import * as React from 'react';
2
+ import { useTableRow_unstable } from './useTableRow';
3
+ import { renderTableRow_unstable } from './renderTableRow';
4
+ import { useTableRowStyles_unstable } from './useTableRowStyles';
5
+ /**
6
+ * TableRow component - TODO: add more docs
7
+ */
8
+
9
+ export const TableRow = /*#__PURE__*/React.forwardRef((props, ref) => {
10
+ const state = useTableRow_unstable(props, ref);
11
+ useTableRowStyles_unstable(state);
12
+ return renderTableRow_unstable(state);
13
+ });
14
+ TableRow.displayName = 'TableRow';
15
+ //# sourceMappingURL=TableRow.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableRow/TableRow.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAZ,MAAuB,OAAvB;AACA,SAAS,oBAAT,QAAqC,eAArC;AACA,SAAS,uBAAT,QAAwC,kBAAxC;AACA,SAAS,0BAAT,QAA2C,qBAA3C;AAIA;;AAEG;;AACH,OAAO,MAAM,QAAQ,gBAAuC,KAAK,CAAC,UAAN,CAAiB,CAAC,KAAD,EAAQ,GAAR,KAAe;EAC1F,MAAM,KAAK,GAAG,oBAAoB,CAAC,KAAD,EAAQ,GAAR,CAAlC;EAEA,0BAA0B,CAAC,KAAD,CAA1B;EACA,OAAO,uBAAuB,CAAC,KAAD,CAA9B;AACD,CAL2D,CAArD;AAOP,QAAQ,CAAC,WAAT,GAAuB,UAAvB","sourcesContent":["import * as React from 'react';\nimport { useTableRow_unstable } from './useTableRow';\nimport { renderTableRow_unstable } from './renderTableRow';\nimport { useTableRowStyles_unstable } from './useTableRowStyles';\nimport type { TableRowProps } from './TableRow.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * TableRow component - TODO: add more docs\n */\nexport const TableRow: ForwardRefComponent<TableRowProps> = React.forwardRef((props, ref) => {\n const state = useTableRow_unstable(props, ref);\n\n useTableRowStyles_unstable(state);\n return renderTableRow_unstable(state);\n});\n\nTableRow.displayName = 'TableRow';\n"],"sourceRoot":""}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=TableRow.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TableRow.types.js","sourceRoot":"","sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableRow/TableRow.types.ts"],"names":[],"mappings":"","sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\nimport { TableContextValue } from '../Table/Table.types';\n\nexport type TableRowSlots = {\n root: Slot<'tr', 'div'>;\n};\n\n/**\n * TableRow Props\n */\nexport type TableRowProps = ComponentProps<TableRowSlots> & {};\n\n/**\n * State used in rendering TableRow\n */\nexport type TableRowState = ComponentState<TableRowSlots> & Pick<TableContextValue, 'noNativeElements' | 'size'>;\n"]}
@@ -0,0 +1,6 @@
1
+ export * from './TableRow';
2
+ export * from './TableRow.types';
3
+ export * from './renderTableRow';
4
+ export * from './useTableRow';
5
+ export * from './useTableRowStyles';
6
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableRow/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC;AAC9B,cAAc,qBAAqB,CAAC","sourcesContent":["export * from './TableRow';\nexport * from './TableRow.types';\nexport * from './renderTableRow';\nexport * from './useTableRow';\nexport * from './useTableRowStyles';\n"]}
@@ -0,0 +1,16 @@
1
+ import * as React from 'react';
2
+ import { getSlots } from '@fluentui/react-utilities';
3
+ /**
4
+ * Render the final JSX of TableRow
5
+ */
6
+
7
+ export const renderTableRow_unstable = state => {
8
+ const {
9
+ slots,
10
+ slotProps
11
+ } = getSlots(state); // TODO Add additional slots in the appropriate place
12
+
13
+ return /*#__PURE__*/React.createElement(slots.root, { ...slotProps.root
14
+ });
15
+ };
16
+ //# sourceMappingURL=renderTableRow.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableRow/renderTableRow.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAZ,MAAuB,OAAvB;AACA,SAAS,QAAT,QAAyB,2BAAzB;AAGA;;AAEG;;AACH,OAAO,MAAM,uBAAuB,GAAI,KAAD,IAAyB;EAC9D,MAAM;IAAE,KAAF;IAAS;EAAT,IAAuB,QAAQ,CAAgB,KAAhB,CAArC,CAD8D,CAG9D;;EACA,oBAAO,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,IAAP,EAAW,EAAA,GAAK,SAAS,CAAC;EAAf,CAAX,CAAP;AACD,CALM","sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { TableRowState, TableRowSlots } from './TableRow.types';\n\n/**\n * Render the final JSX of TableRow\n */\nexport const renderTableRow_unstable = (state: TableRowState) => {\n const { slots, slotProps } = getSlots<TableRowSlots>(state);\n\n // TODO Add additional slots in the appropriate place\n return <slots.root {...slotProps.root} />;\n};\n"],"sourceRoot":""}
@@ -0,0 +1,34 @@
1
+ import { getNativeElementProps } from '@fluentui/react-utilities';
2
+ import { useTableContext } from '../../contexts/tableContext';
3
+ /**
4
+ * Create the state required to render TableRow.
5
+ *
6
+ * The returned state can be modified with hooks such as useTableRowStyles_unstable,
7
+ * before being passed to renderTableRow_unstable.
8
+ *
9
+ * @param props - props from this instance of TableRow
10
+ * @param ref - reference to root HTMLElement of TableRow
11
+ */
12
+
13
+ export const useTableRow_unstable = (props, ref) => {
14
+ var _a;
15
+
16
+ const {
17
+ noNativeElements,
18
+ size
19
+ } = useTableContext();
20
+ const rootComponent = ((_a = props.as) !== null && _a !== void 0 ? _a : noNativeElements) ? 'div' : 'tr';
21
+ return {
22
+ components: {
23
+ root: rootComponent
24
+ },
25
+ root: getNativeElementProps(rootComponent, {
26
+ ref,
27
+ role: rootComponent === 'div' ? 'row' : undefined,
28
+ ...props
29
+ }),
30
+ size,
31
+ noNativeElements
32
+ };
33
+ };
34
+ //# sourceMappingURL=useTableRow.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableRow/useTableRow.ts"],"names":[],"mappings":"AACA,SAAS,qBAAT,QAAsC,2BAAtC;AAEA,SAAS,eAAT,QAAgC,6BAAhC;AAEA;;;;;;;;AAQG;;AACH,OAAO,MAAM,oBAAoB,GAAG,CAAC,KAAD,EAAuB,GAAvB,KAAqE;;;EACvG,MAAM;IAAE,gBAAF;IAAoB;EAApB,IAA6B,eAAe,EAAlD;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,IAA7D;EAEA,OAAO;IACL,UAAU,EAAE;MACV,IAAI,EAAE;IADI,CADP;IAIL,IAAI,EAAE,qBAAqB,CAAC,aAAD,EAAgB;MACzC,GADyC;MAEzC,IAAI,EAAE,aAAa,KAAK,KAAlB,GAA0B,KAA1B,GAAkC,SAFC;MAGzC,GAAG;IAHsC,CAAhB,CAJtB;IASL,IATK;IAUL;EAVK,CAAP;AAYD,CAhBM","sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps } from '@fluentui/react-utilities';\nimport type { TableRowProps, TableRowState } from './TableRow.types';\nimport { useTableContext } from '../../contexts/tableContext';\n\n/**\n * Create the state required to render TableRow.\n *\n * The returned state can be modified with hooks such as useTableRowStyles_unstable,\n * before being passed to renderTableRow_unstable.\n *\n * @param props - props from this instance of TableRow\n * @param ref - reference to root HTMLElement of TableRow\n */\nexport const useTableRow_unstable = (props: TableRowProps, ref: React.Ref<HTMLElement>): TableRowState => {\n const { noNativeElements, size } = useTableContext();\n const rootComponent = props.as ?? noNativeElements ? 'div' : 'tr';\n\n return {\n components: {\n root: rootComponent,\n },\n root: getNativeElementProps(rootComponent, {\n ref,\n role: rootComponent === 'div' ? 'row' : undefined,\n ...props,\n }),\n size,\n noNativeElements,\n };\n};\n"],"sourceRoot":""}
@@ -0,0 +1,88 @@
1
+ import { __styles, mergeClasses, shorthands } from '@griffel/react';
2
+ import { tokens } from '@fluentui/react-theme';
3
+ import { tableCellActionsClassNames } from '../TableCellActions/useTableCellActionsStyles';
4
+ export const tableRowClassName = 'fui-TableRow';
5
+ export const tableRowClassNames = {
6
+ root: tableRowClassName
7
+ };
8
+
9
+ const useTableLayoutStyles = /*#__PURE__*/__styles({
10
+ "root": {
11
+ "mc9l5x": "f1u0rzck"
12
+ },
13
+ "medium": {
14
+ "Bqenvij": "f1ft4266"
15
+ },
16
+ "small": {
17
+ "Bqenvij": "fbsu25e"
18
+ },
19
+ "smaller": {
20
+ "Bqenvij": "frvgh55"
21
+ }
22
+ }, {
23
+ "d": [".f1u0rzck{display:table-row;}", ".f1ft4266{height:44px;}", ".fbsu25e{height:34px;}", ".frvgh55{height:24px;}"]
24
+ });
25
+
26
+ const useFlexLayoutStyles = /*#__PURE__*/__styles({
27
+ "root": {
28
+ "mc9l5x": "f22iagw",
29
+ "Bt984gj": "f122n59"
30
+ },
31
+ "medium": {
32
+ "sshi5w": "f5pgtk9"
33
+ },
34
+ "small": {
35
+ "sshi5w": "fcep9tg"
36
+ },
37
+ "smaller": {
38
+ "sshi5w": "f1pha7fy"
39
+ }
40
+ }, {
41
+ "d": [".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;}", ".f5pgtk9{min-height:44px;}", ".fcep9tg{min-height:34px;}", ".f1pha7fy{min-height:24px;}"]
42
+ });
43
+ /**
44
+ * Styles for the root slot
45
+ */
46
+
47
+
48
+ const useStyles = /*#__PURE__*/__styles({
49
+ "root": {
50
+ "sj55zd": "f19n0e5",
51
+ "Jwef8y": "f1knas48",
52
+ "Bi91k9c": "feu1g3u",
53
+ "Bi7d7a3": "f1boln4s",
54
+ "Bpt6rm4": "f1uorfem",
55
+ "B7ck84d": "f1ewtqcl"
56
+ },
57
+ "medium": {
58
+ "Bn0qgzm": "f1vxd6vx",
59
+ "oivjwe": "fg706s2",
60
+ "B9xav0g": "frpde29"
61
+ },
62
+ "small": {
63
+ "Bn0qgzm": "f1vxd6vx",
64
+ "oivjwe": "fg706s2",
65
+ "B9xav0g": "frpde29"
66
+ },
67
+ "smaller": {
68
+ "Be2twd7": "fy9rknc"
69
+ }
70
+ }, {
71
+ "d": [".f19n0e5{color:var(--colorNeutralForeground1);}", ".f1ewtqcl{box-sizing:border-box;}", ".f1vxd6vx{border-bottom-width:var(--strokeWidthThin);}", ".fg706s2{border-bottom-style:solid;}", ".frpde29{border-bottom-color:var(--colorNeutralStroke2);}", ".fy9rknc{font-size:var(--fontSizeBase200);}"],
72
+ "h": [".f1knas48:hover{background-color:var(--colorNeutralBackground1Hover);}", ".feu1g3u:hover{color:var(--colorNeutralForeground1Hover);}", ".f1boln4s:hover .fui-TableCellActions{background-color:var(--colorNeutralBackground1Hover);}", ".f1uorfem:hover .fui-TableCellActions{opacity:1;}"]
73
+ });
74
+ /**
75
+ * Apply styling to the TableRow slots based on the state
76
+ */
77
+
78
+
79
+ export const useTableRowStyles_unstable = state => {
80
+ const styles = useStyles();
81
+ const layoutStyles = {
82
+ table: useTableLayoutStyles(),
83
+ flex: useFlexLayoutStyles()
84
+ };
85
+ state.root.className = mergeClasses(tableRowClassNames.root, styles.root, styles[state.size], state.noNativeElements ? layoutStyles.flex.root : layoutStyles.table.root, state.noNativeElements ? layoutStyles.flex[state.size] : layoutStyles.table[state.size], state.root.className);
86
+ return state;
87
+ };
88
+ //# sourceMappingURL=useTableRowStyles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableRow/useTableRowStyles.ts"],"names":[],"mappings":"AAAA,mBAAqB,YAArB,EAAmC,UAAnC,QAAqD,gBAArD;AACA,SAAS,MAAT,QAAuB,uBAAvB;AAGA,SAAS,0BAAT,QAA2C,+CAA3C;AAEA,OAAO,MAAM,iBAAiB,GAAG,cAA1B;AACP,OAAO,MAAM,kBAAkB,GAAkC;EAC/D,IAAI,EAAE;AADyD,CAA1D;;AAIP,MAAM,oBAAoB,gBAAG;EAAA;IAAA;EAAA;EAAA;IAAA;EAAA;EAAA;IAAA;EAAA;EAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAA7B;;AAkBA,MAAM,mBAAmB,gBAAG;EAAA;IAAA;IAAA;EAAA;EAAA;IAAA;EAAA;EAAA;IAAA;EAAA;EAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAA5B;AAmBA;;AAEG;;;AACH,MAAM,SAAS,gBAAG;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;EAAA;AAAA;EAAA;EAAA;AAAA,EAAlB;AA2BA;;AAEG;;;AACH,OAAO,MAAM,0BAA0B,GAAI,KAAD,IAAwC;EAChF,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,YAAY,CACjC,kBAAkB,CAAC,IADc,EAEjC,MAAM,CAAC,IAF0B,EAGjC,MAAM,CAAC,KAAK,CAAC,IAAP,CAH2B,EAIjC,KAAK,CAAC,gBAAN,GAAyB,YAAY,CAAC,IAAb,CAAkB,IAA3C,GAAkD,YAAY,CAAC,KAAb,CAAmB,IAJpC,EAKjC,KAAK,CAAC,gBAAN,GAAyB,YAAY,CAAC,IAAb,CAAkB,KAAK,CAAC,IAAxB,CAAzB,GAAyD,YAAY,CAAC,KAAb,CAAmB,KAAK,CAAC,IAAzB,CALxB,EAMjC,KAAK,CAAC,IAAN,CAAW,SANsB,CAAnC;EASA,OAAO,KAAP;AACD,CAhBM","sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens } from '@fluentui/react-theme';\nimport type { TableRowSlots, TableRowState } from './TableRow.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\nimport { tableCellActionsClassNames } from '../TableCellActions/useTableCellActionsStyles';\n\nexport const tableRowClassName = 'fui-TableRow';\nexport const tableRowClassNames: SlotClassNames<TableRowSlots> = {\n root: tableRowClassName,\n};\n\nconst useTableLayoutStyles = makeStyles({\n root: {\n display: 'table-row',\n },\n\n medium: {\n height: '44px',\n },\n\n small: {\n height: '34px',\n },\n\n smaller: {\n height: '24px',\n },\n});\n\nconst useFlexLayoutStyles = makeStyles({\n root: {\n display: 'flex',\n alignItems: 'center',\n },\n\n medium: {\n minHeight: '44px',\n },\n\n small: {\n minHeight: '34px',\n },\n\n smaller: {\n minHeight: '24px',\n },\n});\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n color: tokens.colorNeutralForeground1,\n ':hover': {\n backgroundColor: tokens.colorNeutralBackground1Hover,\n color: tokens.colorNeutralForeground1Hover,\n [`& .${tableCellActionsClassNames.root}`]: {\n backgroundColor: tokens.colorNeutralBackground1Hover,\n opacity: 1,\n },\n },\n boxSizing: 'border-box',\n },\n\n medium: {\n ...shorthands.borderBottom(tokens.strokeWidthThin, 'solid', tokens.colorNeutralStroke2),\n },\n\n small: {\n ...shorthands.borderBottom(tokens.strokeWidthThin, 'solid', tokens.colorNeutralStroke2),\n },\n\n smaller: {\n fontSize: tokens.fontSizeBase200,\n },\n});\n\n/**\n * Apply styling to the TableRow slots based on the state\n */\nexport const useTableRowStyles_unstable = (state: TableRowState): TableRowState => {\n const styles = useStyles();\n const layoutStyles = {\n table: useTableLayoutStyles(),\n flex: useFlexLayoutStyles(),\n };\n state.root.className = mergeClasses(\n tableRowClassNames.root,\n styles.root,\n styles[state.size],\n state.noNativeElements ? layoutStyles.flex.root : layoutStyles.table.root,\n state.noNativeElements ? layoutStyles.flex[state.size] : layoutStyles.table[state.size],\n state.root.className,\n );\n\n return state;\n};\n"],"sourceRoot":""}
@@ -0,0 +1,15 @@
1
+ import * as React from 'react';
2
+ import { useTableSelectionCell_unstable } from './useTableSelectionCell';
3
+ import { renderTableSelectionCell_unstable } from './renderTableSelectionCell';
4
+ import { useTableSelectionCellStyles_unstable } from './useTableSelectionCellStyles';
5
+ /**
6
+ * TableSelectionCell component - TODO: add more docs
7
+ */
8
+
9
+ export const TableSelectionCell = /*#__PURE__*/React.forwardRef((props, ref) => {
10
+ const state = useTableSelectionCell_unstable(props, ref);
11
+ useTableSelectionCellStyles_unstable(state);
12
+ return renderTableSelectionCell_unstable(state);
13
+ });
14
+ TableSelectionCell.displayName = 'TableSelectionCell';
15
+ //# sourceMappingURL=TableSelectionCell.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableSelectionCell/TableSelectionCell.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAZ,MAAuB,OAAvB;AACA,SAAS,8BAAT,QAA+C,yBAA/C;AACA,SAAS,iCAAT,QAAkD,4BAAlD;AACA,SAAS,oCAAT,QAAqD,+BAArD;AAIA;;AAEG;;AACH,OAAO,MAAM,kBAAkB,gBAAiD,KAAK,CAAC,UAAN,CAAiB,CAAC,KAAD,EAAQ,GAAR,KAAe;EAC9G,MAAM,KAAK,GAAG,8BAA8B,CAAC,KAAD,EAAQ,GAAR,CAA5C;EAEA,oCAAoC,CAAC,KAAD,CAApC;EACA,OAAO,iCAAiC,CAAC,KAAD,CAAxC;AACD,CAL+E,CAAzE;AAOP,kBAAkB,CAAC,WAAnB,GAAiC,oBAAjC","sourcesContent":["import * as React from 'react';\nimport { useTableSelectionCell_unstable } from './useTableSelectionCell';\nimport { renderTableSelectionCell_unstable } from './renderTableSelectionCell';\nimport { useTableSelectionCellStyles_unstable } from './useTableSelectionCellStyles';\nimport type { TableSelectionCellProps } from './TableSelectionCell.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * TableSelectionCell component - TODO: add more docs\n */\nexport const TableSelectionCell: ForwardRefComponent<TableSelectionCellProps> = React.forwardRef((props, ref) => {\n const state = useTableSelectionCell_unstable(props, ref);\n\n useTableSelectionCellStyles_unstable(state);\n return renderTableSelectionCell_unstable(state);\n});\n\nTableSelectionCell.displayName = 'TableSelectionCell';\n"],"sourceRoot":""}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=TableSelectionCell.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TableSelectionCell.types.js","sourceRoot":"","sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableSelectionCell/TableSelectionCell.types.ts"],"names":[],"mappings":"","sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\nimport type { Checkbox, CheckboxProps } from '@fluentui/react-checkbox';\nimport { TableCellSlots } from '../TableCell/TableCell.types';\nimport { TableContextValue } from '../Table/Table.types';\n\nexport type TableSelectionCellSlots = {\n /**\n * Selection indicator if selection type is checkbox\n */\n checkboxIndicator: Slot<typeof Checkbox>;\n /**\n * Selection indicator if selection type is radio\n */\n radioIndicator: Slot<'span'>;\n} & Pick<TableCellSlots, 'root'>;\n\n/**\n * TableSelectionCell Props\n */\nexport type TableSelectionCellProps = ComponentProps<Partial<Omit<TableSelectionCellSlots, 'media'>>> & {\n /**\n * A table can have two kinds of selection modes\n */\n type?: 'checkbox' | 'radio';\n checked?: CheckboxProps['checked'];\n};\n\n/**\n * State used in rendering TableSelectionCell\n */\nexport type TableSelectionCellState = ComponentState<TableSelectionCellSlots> &\n Pick<Required<TableSelectionCellProps>, 'type' | 'checked'> &\n Pick<TableContextValue, 'noNativeElements'>;\n"]}
@@ -0,0 +1,6 @@
1
+ export * from './TableSelectionCell';
2
+ export * from './TableSelectionCell.types';
3
+ export * from './renderTableSelectionCell';
4
+ export * from './useTableSelectionCell';
5
+ export * from './useTableSelectionCellStyles';
6
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableSelectionCell/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC;AACrC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,4BAA4B,CAAC;AAC3C,cAAc,yBAAyB,CAAC;AACxC,cAAc,+BAA+B,CAAC","sourcesContent":["export * from './TableSelectionCell';\nexport * from './TableSelectionCell.types';\nexport * from './renderTableSelectionCell';\nexport * from './useTableSelectionCell';\nexport * from './useTableSelectionCellStyles';\n"]}
@@ -0,0 +1,17 @@
1
+ import * as React from 'react';
2
+ import { getSlots } from '@fluentui/react-utilities';
3
+ /**
4
+ * Render the final JSX of TableSelectionCell
5
+ */
6
+
7
+ export const renderTableSelectionCell_unstable = state => {
8
+ const {
9
+ slots,
10
+ slotProps
11
+ } = getSlots(state);
12
+ return /*#__PURE__*/React.createElement(slots.root, { ...slotProps.root
13
+ }, state.type === 'checkbox' && slots.checkboxIndicator && /*#__PURE__*/React.createElement(slots.checkboxIndicator, { ...slotProps.checkboxIndicator
14
+ }), state.type === 'radio' && slots.radioIndicator && /*#__PURE__*/React.createElement(slots.radioIndicator, { ...slotProps.radioIndicator
15
+ }));
16
+ };
17
+ //# sourceMappingURL=renderTableSelectionCell.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableSelectionCell/renderTableSelectionCell.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAZ,MAAuB,OAAvB;AACA,SAAS,QAAT,QAAyB,2BAAzB;AAGA;;AAEG;;AACH,OAAO,MAAM,iCAAiC,GAAI,KAAD,IAAmC;EAClF,MAAM;IAAE,KAAF;IAAS;EAAT,IAAuB,QAAQ,CAA0B,KAA1B,CAArC;EAEA,oBACE,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,IAAP,EAAW,EAAA,GAAK,SAAS,CAAC;EAAf,CAAX,EACG,KAAK,CAAC,IAAN,KAAe,UAAf,IAA6B,KAAK,CAAC,iBAAnC,iBACC,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,iBAAP,EAAwB,EAAA,GAAK,SAAS,CAAC;EAAf,CAAxB,CAFJ,EAIG,KAAK,CAAC,IAAN,KAAe,OAAf,IAA0B,KAAK,CAAC,cAAhC,iBAAkD,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,cAAP,EAAqB,EAAA,GAAK,SAAS,CAAC;EAAf,CAArB,CAJrD,CADF;AAQD,CAXM","sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { TableSelectionCellState, TableSelectionCellSlots } from './TableSelectionCell.types';\n\n/**\n * Render the final JSX of TableSelectionCell\n */\nexport const renderTableSelectionCell_unstable = (state: TableSelectionCellState) => {\n const { slots, slotProps } = getSlots<TableSelectionCellSlots>(state);\n\n return (\n <slots.root {...slotProps.root}>\n {state.type === 'checkbox' && slots.checkboxIndicator && (\n <slots.checkboxIndicator {...slotProps.checkboxIndicator} />\n )}\n {state.type === 'radio' && slots.radioIndicator && <slots.radioIndicator {...slotProps.radioIndicator} />}\n </slots.root>\n );\n};\n"],"sourceRoot":""}
@@ -0,0 +1,47 @@
1
+ import * as React from 'react';
2
+ import { resolveShorthand } from '@fluentui/react-utilities';
3
+ import { Checkbox } from '@fluentui/react-checkbox';
4
+ import { CheckmarkFilled } from '@fluentui/react-icons';
5
+ import { useTableCell_unstable } from '../TableCell/useTableCell';
6
+ import { useTableContext } from '../../contexts/tableContext';
7
+ /**
8
+ * Create the state required to render TableSelectionCell.
9
+ *
10
+ * The returned state can be modified with hooks such as useTableSelectionCellStyles_unstable,
11
+ * before being passed to renderTableSelectionCell_unstable.
12
+ *
13
+ * @param props - props from this instance of TableSelectionCell
14
+ * @param ref - reference to root HTMLElement of TableSelectionCell
15
+ */
16
+
17
+ export const useTableSelectionCell_unstable = (props, ref) => {
18
+ var _a, _b;
19
+
20
+ const tableCellState = useTableCell_unstable(props, ref);
21
+ const {
22
+ noNativeElements
23
+ } = useTableContext();
24
+ const type = (_a = props.type) !== null && _a !== void 0 ? _a : 'checkbox';
25
+ return { ...tableCellState,
26
+ components: { ...tableCellState.components,
27
+ checkboxIndicator: Checkbox,
28
+ radioIndicator: 'span'
29
+ },
30
+ checkboxIndicator: resolveShorthand(props.checkboxIndicator, {
31
+ required: type === 'checkbox',
32
+ defaultProps: {
33
+ checked: props.checked
34
+ }
35
+ }),
36
+ radioIndicator: resolveShorthand(props.radioIndicator, {
37
+ required: type === 'radio',
38
+ defaultProps: {
39
+ children: /*#__PURE__*/React.createElement(CheckmarkFilled, null)
40
+ }
41
+ }),
42
+ type,
43
+ checked: (_b = props.checked) !== null && _b !== void 0 ? _b : false,
44
+ noNativeElements
45
+ };
46
+ };
47
+ //# sourceMappingURL=useTableSelectionCell.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableSelectionCell/useTableSelectionCell.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAZ,MAAuB,OAAvB;AACA,SAAS,gBAAT,QAAiC,2BAAjC;AACA,SAAS,QAAT,QAAyB,0BAAzB;AACA,SAAS,eAAT,QAAgC,uBAAhC;AAEA,SAAS,qBAAT,QAAsC,2BAAtC;AACA,SAAS,eAAT,QAAgC,6BAAhC;AAEA;;;;;;;;AAQG;;AACH,OAAO,MAAM,8BAA8B,GAAG,CAC5C,KAD4C,EAE5C,GAF4C,KAGjB;;;EAC3B,MAAM,cAAc,GAAG,qBAAqB,CAAC,KAAD,EAAQ,GAAR,CAA5C;EACA,MAAM;IAAE;EAAF,IAAuB,eAAe,EAA5C;EACA,MAAM,IAAI,GAAG,CAAA,EAAA,GAAA,KAAK,CAAC,IAAN,MAAU,IAAV,IAAU,EAAA,KAAA,KAAA,CAAV,GAAU,EAAV,GAAc,UAA3B;EAEA,OAAO,EACL,GAAG,cADE;IAEL,UAAU,EAAE,EACV,GAAG,cAAc,CAAC,UADR;MAEV,iBAAiB,EAAE,QAFT;MAGV,cAAc,EAAE;IAHN,CAFP;IAOL,iBAAiB,EAAE,gBAAgB,CAAC,KAAK,CAAC,iBAAP,EAA0B;MAC3D,QAAQ,EAAE,IAAI,KAAK,UADwC;MAE3D,YAAY,EAAE;QAAE,OAAO,EAAE,KAAK,CAAC;MAAjB;IAF6C,CAA1B,CAP9B;IAWL,cAAc,EAAE,gBAAgB,CAAC,KAAK,CAAC,cAAP,EAAuB;MACrD,QAAQ,EAAE,IAAI,KAAK,OADkC;MAErD,YAAY,EAAE;QAAE,QAAQ,eAAE,KAAA,CAAA,aAAA,CAAC,eAAD,EAAgB,IAAhB;MAAZ;IAFuC,CAAvB,CAX3B;IAeL,IAfK;IAgBL,OAAO,EAAE,CAAA,EAAA,GAAA,KAAK,CAAC,OAAN,MAAa,IAAb,IAAa,EAAA,KAAA,KAAA,CAAb,GAAa,EAAb,GAAiB,KAhBrB;IAiBL;EAjBK,CAAP;AAmBD,CA3BM","sourcesContent":["import * as React from 'react';\nimport { resolveShorthand } from '@fluentui/react-utilities';\nimport { Checkbox } from '@fluentui/react-checkbox';\nimport { CheckmarkFilled } from '@fluentui/react-icons';\nimport type { TableSelectionCellProps, TableSelectionCellState } from './TableSelectionCell.types';\nimport { useTableCell_unstable } from '../TableCell/useTableCell';\nimport { useTableContext } from '../../contexts/tableContext';\n\n/**\n * Create the state required to render TableSelectionCell.\n *\n * The returned state can be modified with hooks such as useTableSelectionCellStyles_unstable,\n * before being passed to renderTableSelectionCell_unstable.\n *\n * @param props - props from this instance of TableSelectionCell\n * @param ref - reference to root HTMLElement of TableSelectionCell\n */\nexport const useTableSelectionCell_unstable = (\n props: TableSelectionCellProps,\n ref: React.Ref<HTMLElement>,\n): TableSelectionCellState => {\n const tableCellState = useTableCell_unstable(props, ref);\n const { noNativeElements } = useTableContext();\n const type = props.type ?? 'checkbox';\n\n return {\n ...tableCellState,\n components: {\n ...tableCellState.components,\n checkboxIndicator: Checkbox,\n radioIndicator: 'span',\n },\n checkboxIndicator: resolveShorthand(props.checkboxIndicator, {\n required: type === 'checkbox',\n defaultProps: { checked: props.checked },\n }),\n radioIndicator: resolveShorthand(props.radioIndicator, {\n required: type === 'radio',\n defaultProps: { children: <CheckmarkFilled /> },\n }),\n type,\n checked: props.checked ?? false,\n noNativeElements,\n };\n};\n"],"sourceRoot":""}
@@ -0,0 +1,81 @@
1
+ import { __styles, mergeClasses, shorthands } from '@griffel/react';
2
+ export const tableSelectionCellClassNames = {
3
+ root: 'fui-TableSelectionCell',
4
+ checkboxIndicator: 'fui-TableSelectionCell__checkboxIndicator',
5
+ radioIndicator: 'fui-TableSelectionCell__radioIndicator'
6
+ };
7
+
8
+ const useTableLayoutStyles = /*#__PURE__*/__styles({
9
+ "root": {
10
+ "mc9l5x": "f15pt5es",
11
+ "a9b677": "fksc0bp"
12
+ }
13
+ }, {
14
+ "d": [".f15pt5es{display:table-cell;}", ".fksc0bp{width:44px;}"]
15
+ });
16
+
17
+ const useFlexLayoutStyles = /*#__PURE__*/__styles({
18
+ "root": {
19
+ "mc9l5x": "f22iagw",
20
+ "Bh6795r": "fqerorx",
21
+ "Bnnss6s": "f1neuvcm",
22
+ "xawz": "fkjuxzh",
23
+ "Bf4jedk": "fvrlu0f",
24
+ "B2u0y6b": "f1c71y05",
25
+ "Brf1p80": "f4d9j23"
26
+ }
27
+ }, {
28
+ "d": [".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}", ".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;}", ".fvrlu0f{min-width:44px;}", ".f1c71y05{max-width:44px;}", ".f4d9j23{-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;}"]
29
+ });
30
+ /**
31
+ * Styles for the root slot
32
+ */
33
+
34
+
35
+ const useStyles = /*#__PURE__*/__styles({
36
+ "root": {
37
+ "fsow6f": "f17mccla",
38
+ "Huce71": "fz5stix",
39
+ "z8tnut": "f1g0x7ka",
40
+ "z189sj": ["fhxju0i", "f1cnd47f"],
41
+ "Byoj8tv": "f1qch9an",
42
+ "uwmqm3": ["f1cnd47f", "fhxju0i"]
43
+ },
44
+ "radioIndicator": {
45
+ "mc9l5x": "f22iagw",
46
+ "Bh6795r": "fqerorx",
47
+ "Bt984gj": "f122n59",
48
+ "Brf1p80": "f4d9j23",
49
+ "B5pe6w7": "f1cqkysu",
50
+ "p4uzdd": "f1sgf1mg"
51
+ },
52
+ "hidden": {
53
+ "Bcdw1i0": "fd7fpy0"
54
+ }
55
+ }, {
56
+ "d": [".f17mccla{text-align:center;}", ".fz5stix{white-space:nowrap;}", ".f1g0x7ka{padding-top:0;}", ".fhxju0i{padding-right:0;}", ".f1cnd47f{padding-left:0;}", ".f1qch9an{padding-bottom:0;}", ".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}", ".fqerorx{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}", ".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}", ".f4d9j23{-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;}", ".f1cqkysu svg{width:16px;}", ".f1sgf1mg svg{height:16px;}", ".fd7fpy0{visibility:hidden;}"]
57
+ });
58
+ /**
59
+ * Apply styling to the TableSelectionCell slots based on the state
60
+ */
61
+
62
+
63
+ export const useTableSelectionCellStyles_unstable = state => {
64
+ const styles = useStyles();
65
+ const layoutStyles = {
66
+ table: useTableLayoutStyles(),
67
+ flex: useFlexLayoutStyles()
68
+ };
69
+ state.root.className = mergeClasses(tableSelectionCellClassNames.root, styles.root, state.noNativeElements ? layoutStyles.flex.root : layoutStyles.table.root, state.root.className);
70
+
71
+ if (state.checkboxIndicator) {
72
+ state.checkboxIndicator.className = mergeClasses(tableSelectionCellClassNames.checkboxIndicator, state.checkboxIndicator.className);
73
+ }
74
+
75
+ if (state.radioIndicator) {
76
+ state.radioIndicator.className = mergeClasses(tableSelectionCellClassNames.radioIndicator, styles.radioIndicator, state.checked === false && styles.hidden, state.radioIndicator.className);
77
+ }
78
+
79
+ return state;
80
+ };
81
+ //# sourceMappingURL=useTableSelectionCellStyles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../../../../packages/react-components/react-table/src/components/TableSelectionCell/useTableSelectionCellStyles.ts"],"names":[],"mappings":"AAAA,mBAAqB,YAArB,EAAmC,UAAnC,QAAqD,gBAArD;AAIA,OAAO,MAAM,4BAA4B,GAA4C;EACnF,IAAI,EAAE,wBAD6E;EAEnF,iBAAiB,EAAE,2CAFgE;EAGnF,cAAc,EAAE;AAHmE,CAA9E;;AAMP,MAAM,oBAAoB,gBAAG;EAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAA7B;;AAOA,MAAM,mBAAmB,gBAAG;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAA5B;AAUA;;AAEG;;;AACH,MAAM,SAAS,gBAAG;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAAlB;AAuBA;;AAEG;;;AACH,OAAO,MAAM,oCAAoC,GAAI,KAAD,IAA4D;EAC9G,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,YAAY,CACjC,4BAA4B,CAAC,IADI,EAEjC,MAAM,CAAC,IAF0B,EAGjC,KAAK,CAAC,gBAAN,GAAyB,YAAY,CAAC,IAAb,CAAkB,IAA3C,GAAkD,YAAY,CAAC,KAAb,CAAmB,IAHpC,EAIjC,KAAK,CAAC,IAAN,CAAW,SAJsB,CAAnC;;EAMA,IAAI,KAAK,CAAC,iBAAV,EAA6B;IAC3B,KAAK,CAAC,iBAAN,CAAwB,SAAxB,GAAoC,YAAY,CAC9C,4BAA4B,CAAC,iBADiB,EAE9C,KAAK,CAAC,iBAAN,CAAwB,SAFsB,CAAhD;EAID;;EAED,IAAI,KAAK,CAAC,cAAV,EAA0B;IACxB,KAAK,CAAC,cAAN,CAAqB,SAArB,GAAiC,YAAY,CAC3C,4BAA4B,CAAC,cADc,EAE3C,MAAM,CAAC,cAFoC,EAG3C,KAAK,CAAC,OAAN,KAAkB,KAAlB,IAA2B,MAAM,CAAC,MAHS,EAI3C,KAAK,CAAC,cAAN,CAAqB,SAJsB,CAA7C;EAMD;;EAED,OAAO,KAAP;AACD,CA7BM","sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport type { TableSelectionCellSlots, TableSelectionCellState } from './TableSelectionCell.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\n\nexport const tableSelectionCellClassNames: SlotClassNames<TableSelectionCellSlots> = {\n root: 'fui-TableSelectionCell',\n checkboxIndicator: 'fui-TableSelectionCell__checkboxIndicator',\n radioIndicator: 'fui-TableSelectionCell__radioIndicator',\n};\n\nconst useTableLayoutStyles = makeStyles({\n root: {\n display: 'table-cell',\n width: '44px',\n },\n});\n\nconst useFlexLayoutStyles = makeStyles({\n root: {\n display: 'flex',\n ...shorthands.flex(1, 1, '0px'),\n minWidth: '44px',\n maxWidth: '44px',\n justifyContent: 'center',\n },\n});\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n textAlign: 'center',\n whiteSpace: 'nowrap',\n ...shorthands.padding(0),\n },\n\n radioIndicator: {\n display: 'flex',\n flexGrow: 1,\n alignItems: 'center',\n justifyContent: 'center',\n '& svg': {\n width: '16px',\n height: '16px',\n },\n },\n\n hidden: {\n visibility: 'hidden',\n },\n});\n\n/**\n * Apply styling to the TableSelectionCell slots based on the state\n */\nexport const useTableSelectionCellStyles_unstable = (state: TableSelectionCellState): TableSelectionCellState => {\n const styles = useStyles();\n const layoutStyles = {\n table: useTableLayoutStyles(),\n flex: useFlexLayoutStyles(),\n };\n state.root.className = mergeClasses(\n tableSelectionCellClassNames.root,\n styles.root,\n state.noNativeElements ? layoutStyles.flex.root : layoutStyles.table.root,\n state.root.className,\n );\n if (state.checkboxIndicator) {\n state.checkboxIndicator.className = mergeClasses(\n tableSelectionCellClassNames.checkboxIndicator,\n state.checkboxIndicator.className,\n );\n }\n\n if (state.radioIndicator) {\n state.radioIndicator.className = mergeClasses(\n tableSelectionCellClassNames.radioIndicator,\n styles.radioIndicator,\n state.checked === false && styles.hidden,\n state.radioIndicator.className,\n );\n }\n\n return state;\n};\n"],"sourceRoot":""}
@@ -0,0 +1,14 @@
1
+ import * as React from 'react';
2
+ const tableContext = /*#__PURE__*/React.createContext(undefined);
3
+ export const tableContextDefaultValue = {
4
+ size: 'medium',
5
+ noNativeElements: false,
6
+ sortable: false
7
+ };
8
+ export const TableContextProvider = tableContext.Provider;
9
+ export const useTableContext = () => {
10
+ var _a;
11
+
12
+ return (_a = React.useContext(tableContext)) !== null && _a !== void 0 ? _a : tableContextDefaultValue;
13
+ };
14
+ //# sourceMappingURL=tableContext.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../../../packages/react-components/react-table/src/contexts/tableContext.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAZ,MAAuB,OAAvB;AAGA,MAAM,YAAY,gBAAG,KAAK,CAAC,aAAN,CAAmD,SAAnD,CAArB;AAEA,OAAO,MAAM,wBAAwB,GAAsB;EACzD,IAAI,EAAE,QADmD;EAEzD,gBAAgB,EAAE,KAFuC;EAGzD,QAAQ,EAAE;AAH+C,CAApD;AAMP,OAAO,MAAM,oBAAoB,GAAG,YAAY,CAAC,QAA1C;AACP,OAAO,MAAM,eAAe,GAAG,MAAK;EAAA,IAAA,EAAA;;EAAC,OAAA,CAAA,EAAA,GAAA,KAAK,CAAC,UAAN,CAAiB,YAAjB,CAAA,MAA8B,IAA9B,IAA8B,EAAA,KAAA,KAAA,CAA9B,GAA8B,EAA9B,GAAkC,wBAAlC;AAA0D,CAAxF","sourcesContent":["import * as React from 'react';\nimport { TableContextValue } from '../components/Table/Table.types';\n\nconst tableContext = React.createContext<TableContextValue | undefined>(undefined);\n\nexport const tableContextDefaultValue: TableContextValue = {\n size: 'medium',\n noNativeElements: false,\n sortable: false,\n};\n\nexport const TableContextProvider = tableContext.Provider;\nexport const useTableContext = () => React.useContext(tableContext) ?? tableContextDefaultValue;\n"],"sourceRoot":""}
@@ -0,0 +1,5 @@
1
+ export * from './types';
2
+ export * from './useTable';
3
+ export * from './useSort';
4
+ export * from './useSelection';
5
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../../packages/react-components/react-table/src/hooks/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,gBAAgB,CAAC","sourcesContent":["export * from './types';\nexport * from './useTable';\nexport * from './useSort';\nexport * from './useSelection';\n"]}