@cratis/showrunner.usher.react 0.0.0-bootstrap.0 → 0.0.0-stage

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 (507) hide show
  1. package/README.md +2 -71
  2. package/package.json +4 -83
  3. package/Buttons/MyIssuesButton.tsx +0 -78
  4. package/Buttons/ReportButton.tsx +0 -51
  5. package/Buttons/buttonModels.ts +0 -55
  6. package/Buttons/index.ts +0 -6
  7. package/Correlation/CorrelationTracker.ts +0 -51
  8. package/Correlation/index.ts +0 -5
  9. package/Correlation/withCorrelationIdHeader.ts +0 -44
  10. package/Icons.tsx +0 -29
  11. package/Issues/IssueView/AccessPanel.tsx +0 -85
  12. package/Issues/IssueView/GrantAccessDialog.tsx +0 -56
  13. package/Issues/IssueView/IdentityPanel.tsx +0 -38
  14. package/Issues/IssueView/IssueActions.tsx +0 -52
  15. package/Issues/IssueView/IssueConversationPanel.tsx +0 -89
  16. package/Issues/IssueView/IssueHeader.tsx +0 -69
  17. package/Issues/IssueView/IssueView.tsx +0 -74
  18. package/Issues/IssueView/QuestionBanner.tsx +0 -27
  19. package/Issues/IssueView/ReopenIssueDialog.tsx +0 -37
  20. package/Issues/IssueView/ShareIdentityDialog.tsx +0 -37
  21. package/Issues/IssueView/StatusStrip.tsx +0 -42
  22. package/Issues/IssueView/SupportSessions.tsx +0 -59
  23. package/Issues/IssueView/index.ts +0 -15
  24. package/Issues/MyIssues/IssueList.tsx +0 -78
  25. package/Issues/MyIssues/MyIssuesDialog.tsx +0 -64
  26. package/Issues/MyIssues/MyIssuesNavigation.ts +0 -61
  27. package/Issues/MyIssues/index.ts +0 -6
  28. package/Issues/MyIssuesList.ts +0 -33
  29. package/Issues/accessStatus.ts +0 -68
  30. package/Issues/conversationMessages.ts +0 -136
  31. package/Issues/index.ts +0 -12
  32. package/Issues/issueStates.ts +0 -69
  33. package/Issues/sessionActivity.ts +0 -43
  34. package/Issues/useAccessStatus.ts +0 -24
  35. package/Issues/webAddress.ts +0 -22
  36. package/Labels/UsherLabels.ts +0 -365
  37. package/Labels/defaultUsherLabels.ts +0 -178
  38. package/Labels/format.ts +0 -13
  39. package/Labels/index.ts +0 -7
  40. package/Labels/resolveLabels.ts +0 -36
  41. package/Provider/UsherBoundary.tsx +0 -30
  42. package/Provider/UsherContext.ts +0 -109
  43. package/Provider/UsherProvider.tsx +0 -134
  44. package/Provider/index.ts +0 -7
  45. package/Provider/useUsher.ts +0 -72
  46. package/Reporting/AccessChoice.ts +0 -107
  47. package/Reporting/AccessFields.tsx +0 -74
  48. package/Reporting/AccessNotice.tsx +0 -33
  49. package/Reporting/ReportErrorDialog.tsx +0 -94
  50. package/Reporting/ReportIssueDialog.tsx +0 -80
  51. package/Reporting/ReportLimits.ts +0 -24
  52. package/Reporting/ReportSent.ts +0 -12
  53. package/Reporting/SentWithReport.tsx +0 -37
  54. package/Reporting/TechnicalDetails.tsx +0 -60
  55. package/Reporting/durationOptions.ts +0 -31
  56. package/Reporting/formatLocation.ts +0 -27
  57. package/Reporting/index.ts +0 -16
  58. package/Reporting/reportValues.ts +0 -150
  59. package/Reporting/useAccessChoice.ts +0 -53
  60. package/dist/cjs/Buttons/MyIssuesButton.d.ts +0 -14
  61. package/dist/cjs/Buttons/MyIssuesButton.d.ts.map +0 -1
  62. package/dist/cjs/Buttons/MyIssuesButton.js +0 -76
  63. package/dist/cjs/Buttons/MyIssuesButton.js.map +0 -1
  64. package/dist/cjs/Buttons/ReportButton.d.ts +0 -8
  65. package/dist/cjs/Buttons/ReportButton.d.ts.map +0 -1
  66. package/dist/cjs/Buttons/ReportButton.js +0 -34
  67. package/dist/cjs/Buttons/ReportButton.js.map +0 -1
  68. package/dist/cjs/Buttons/buttonModels.d.ts +0 -10
  69. package/dist/cjs/Buttons/buttonModels.d.ts.map +0 -1
  70. package/dist/cjs/Buttons/buttonModels.js +0 -44
  71. package/dist/cjs/Buttons/buttonModels.js.map +0 -1
  72. package/dist/cjs/Buttons/index.d.ts +0 -4
  73. package/dist/cjs/Buttons/index.d.ts.map +0 -1
  74. package/dist/cjs/Correlation/CorrelationTracker.d.ts +0 -10
  75. package/dist/cjs/Correlation/CorrelationTracker.d.ts.map +0 -1
  76. package/dist/cjs/Correlation/CorrelationTracker.js +0 -50
  77. package/dist/cjs/Correlation/CorrelationTracker.js.map +0 -1
  78. package/dist/cjs/Correlation/index.d.ts +0 -3
  79. package/dist/cjs/Correlation/index.d.ts.map +0 -1
  80. package/dist/cjs/Correlation/withCorrelationIdHeader.d.ts +0 -6
  81. package/dist/cjs/Correlation/withCorrelationIdHeader.d.ts.map +0 -1
  82. package/dist/cjs/Correlation/withCorrelationIdHeader.js +0 -39
  83. package/dist/cjs/Correlation/withCorrelationIdHeader.js.map +0 -1
  84. package/dist/cjs/Icons.d.ts +0 -4
  85. package/dist/cjs/Icons.d.ts.map +0 -1
  86. package/dist/cjs/Icons.js +0 -53
  87. package/dist/cjs/Icons.js.map +0 -1
  88. package/dist/cjs/Issues/IssueView/AccessPanel.d.ts +0 -6
  89. package/dist/cjs/Issues/IssueView/AccessPanel.d.ts.map +0 -1
  90. package/dist/cjs/Issues/IssueView/AccessPanel.js +0 -124
  91. package/dist/cjs/Issues/IssueView/AccessPanel.js.map +0 -1
  92. package/dist/cjs/Issues/IssueView/GrantAccessDialog.d.ts +0 -6
  93. package/dist/cjs/Issues/IssueView/GrantAccessDialog.d.ts.map +0 -1
  94. package/dist/cjs/Issues/IssueView/GrantAccessDialog.js +0 -56
  95. package/dist/cjs/Issues/IssueView/GrantAccessDialog.js.map +0 -1
  96. package/dist/cjs/Issues/IssueView/IdentityPanel.d.ts +0 -6
  97. package/dist/cjs/Issues/IssueView/IdentityPanel.d.ts.map +0 -1
  98. package/dist/cjs/Issues/IssueView/IdentityPanel.js +0 -45
  99. package/dist/cjs/Issues/IssueView/IdentityPanel.js.map +0 -1
  100. package/dist/cjs/Issues/IssueView/IssueActions.d.ts +0 -6
  101. package/dist/cjs/Issues/IssueView/IssueActions.d.ts.map +0 -1
  102. package/dist/cjs/Issues/IssueView/IssueActions.js +0 -58
  103. package/dist/cjs/Issues/IssueView/IssueActions.js.map +0 -1
  104. package/dist/cjs/Issues/IssueView/IssueConversationPanel.d.ts +0 -6
  105. package/dist/cjs/Issues/IssueView/IssueConversationPanel.d.ts.map +0 -1
  106. package/dist/cjs/Issues/IssueView/IssueConversationPanel.js +0 -97
  107. package/dist/cjs/Issues/IssueView/IssueConversationPanel.js.map +0 -1
  108. package/dist/cjs/Issues/IssueView/IssueHeader.d.ts +0 -7
  109. package/dist/cjs/Issues/IssueView/IssueHeader.d.ts.map +0 -1
  110. package/dist/cjs/Issues/IssueView/IssueHeader.js +0 -94
  111. package/dist/cjs/Issues/IssueView/IssueHeader.js.map +0 -1
  112. package/dist/cjs/Issues/IssueView/IssueView.d.ts +0 -7
  113. package/dist/cjs/Issues/IssueView/IssueView.d.ts.map +0 -1
  114. package/dist/cjs/Issues/IssueView/IssueView.js +0 -85
  115. package/dist/cjs/Issues/IssueView/IssueView.js.map +0 -1
  116. package/dist/cjs/Issues/IssueView/QuestionBanner.d.ts +0 -5
  117. package/dist/cjs/Issues/IssueView/QuestionBanner.d.ts.map +0 -1
  118. package/dist/cjs/Issues/IssueView/QuestionBanner.js +0 -24
  119. package/dist/cjs/Issues/IssueView/QuestionBanner.js.map +0 -1
  120. package/dist/cjs/Issues/IssueView/ReopenIssueDialog.d.ts +0 -6
  121. package/dist/cjs/Issues/IssueView/ReopenIssueDialog.d.ts.map +0 -1
  122. package/dist/cjs/Issues/IssueView/ReopenIssueDialog.js +0 -34
  123. package/dist/cjs/Issues/IssueView/ReopenIssueDialog.js.map +0 -1
  124. package/dist/cjs/Issues/IssueView/ShareIdentityDialog.d.ts +0 -6
  125. package/dist/cjs/Issues/IssueView/ShareIdentityDialog.d.ts.map +0 -1
  126. package/dist/cjs/Issues/IssueView/ShareIdentityDialog.js +0 -32
  127. package/dist/cjs/Issues/IssueView/ShareIdentityDialog.js.map +0 -1
  128. package/dist/cjs/Issues/IssueView/StatusStrip.d.ts +0 -6
  129. package/dist/cjs/Issues/IssueView/StatusStrip.d.ts.map +0 -1
  130. package/dist/cjs/Issues/IssueView/StatusStrip.js +0 -31
  131. package/dist/cjs/Issues/IssueView/StatusStrip.js.map +0 -1
  132. package/dist/cjs/Issues/IssueView/SupportSessions.d.ts +0 -7
  133. package/dist/cjs/Issues/IssueView/SupportSessions.d.ts.map +0 -1
  134. package/dist/cjs/Issues/IssueView/SupportSessions.js +0 -62
  135. package/dist/cjs/Issues/IssueView/SupportSessions.js.map +0 -1
  136. package/dist/cjs/Issues/IssueView/index.d.ts +0 -13
  137. package/dist/cjs/Issues/IssueView/index.d.ts.map +0 -1
  138. package/dist/cjs/Issues/MyIssues/IssueList.d.ts +0 -7
  139. package/dist/cjs/Issues/MyIssues/IssueList.d.ts.map +0 -1
  140. package/dist/cjs/Issues/MyIssues/IssueList.js +0 -92
  141. package/dist/cjs/Issues/MyIssues/IssueList.js.map +0 -1
  142. package/dist/cjs/Issues/MyIssues/MyIssuesDialog.d.ts +0 -7
  143. package/dist/cjs/Issues/MyIssues/MyIssuesDialog.d.ts.map +0 -1
  144. package/dist/cjs/Issues/MyIssues/MyIssuesDialog.js +0 -79
  145. package/dist/cjs/Issues/MyIssues/MyIssuesDialog.js.map +0 -1
  146. package/dist/cjs/Issues/MyIssues/MyIssuesNavigation.d.ts +0 -21
  147. package/dist/cjs/Issues/MyIssues/MyIssuesNavigation.d.ts.map +0 -1
  148. package/dist/cjs/Issues/MyIssues/MyIssuesNavigation.js +0 -52
  149. package/dist/cjs/Issues/MyIssues/MyIssuesNavigation.js.map +0 -1
  150. package/dist/cjs/Issues/MyIssues/index.d.ts +0 -4
  151. package/dist/cjs/Issues/MyIssues/index.d.ts.map +0 -1
  152. package/dist/cjs/Issues/MyIssuesList.d.ts +0 -7
  153. package/dist/cjs/Issues/MyIssuesList.d.ts.map +0 -1
  154. package/dist/cjs/Issues/MyIssuesList.js +0 -33
  155. package/dist/cjs/Issues/MyIssuesList.js.map +0 -1
  156. package/dist/cjs/Issues/accessStatus.d.ts +0 -13
  157. package/dist/cjs/Issues/accessStatus.d.ts.map +0 -1
  158. package/dist/cjs/Issues/accessStatus.js +0 -60
  159. package/dist/cjs/Issues/accessStatus.js.map +0 -1
  160. package/dist/cjs/Issues/conversationMessages.d.ts +0 -14
  161. package/dist/cjs/Issues/conversationMessages.d.ts.map +0 -1
  162. package/dist/cjs/Issues/conversationMessages.js +0 -131
  163. package/dist/cjs/Issues/conversationMessages.js.map +0 -1
  164. package/dist/cjs/Issues/index.d.ts +0 -10
  165. package/dist/cjs/Issues/index.d.ts.map +0 -1
  166. package/dist/cjs/Issues/issueStates.d.ts +0 -12
  167. package/dist/cjs/Issues/issueStates.d.ts.map +0 -1
  168. package/dist/cjs/Issues/issueStates.js +0 -86
  169. package/dist/cjs/Issues/issueStates.js.map +0 -1
  170. package/dist/cjs/Issues/sessionActivity.d.ts +0 -8
  171. package/dist/cjs/Issues/sessionActivity.d.ts.map +0 -1
  172. package/dist/cjs/Issues/sessionActivity.js +0 -39
  173. package/dist/cjs/Issues/sessionActivity.js.map +0 -1
  174. package/dist/cjs/Issues/useAccessStatus.d.ts +0 -4
  175. package/dist/cjs/Issues/useAccessStatus.d.ts.map +0 -1
  176. package/dist/cjs/Issues/useAccessStatus.js +0 -30
  177. package/dist/cjs/Issues/useAccessStatus.js.map +0 -1
  178. package/dist/cjs/Issues/webAddress.d.ts +0 -2
  179. package/dist/cjs/Issues/webAddress.d.ts.map +0 -1
  180. package/dist/cjs/Issues/webAddress.js +0 -24
  181. package/dist/cjs/Issues/webAddress.js.map +0 -1
  182. package/dist/cjs/Labels/UsherLabels.d.ts +0 -177
  183. package/dist/cjs/Labels/UsherLabels.d.ts.map +0 -1
  184. package/dist/cjs/Labels/defaultUsherLabels.d.ts +0 -3
  185. package/dist/cjs/Labels/defaultUsherLabels.d.ts.map +0 -1
  186. package/dist/cjs/Labels/defaultUsherLabels.js +0 -179
  187. package/dist/cjs/Labels/defaultUsherLabels.js.map +0 -1
  188. package/dist/cjs/Labels/format.d.ts +0 -2
  189. package/dist/cjs/Labels/format.d.ts.map +0 -1
  190. package/dist/cjs/Labels/format.js +0 -15
  191. package/dist/cjs/Labels/format.js.map +0 -1
  192. package/dist/cjs/Labels/index.d.ts +0 -5
  193. package/dist/cjs/Labels/index.d.ts.map +0 -1
  194. package/dist/cjs/Labels/resolveLabels.d.ts +0 -3
  195. package/dist/cjs/Labels/resolveLabels.d.ts.map +0 -1
  196. package/dist/cjs/Labels/resolveLabels.js +0 -35
  197. package/dist/cjs/Labels/resolveLabels.js.map +0 -1
  198. package/dist/cjs/Provider/UsherBoundary.d.ts +0 -6
  199. package/dist/cjs/Provider/UsherBoundary.d.ts.map +0 -1
  200. package/dist/cjs/Provider/UsherBoundary.js +0 -24
  201. package/dist/cjs/Provider/UsherBoundary.js.map +0 -1
  202. package/dist/cjs/Provider/UsherContext.d.ts +0 -24
  203. package/dist/cjs/Provider/UsherContext.d.ts.map +0 -1
  204. package/dist/cjs/Provider/UsherContext.js +0 -41
  205. package/dist/cjs/Provider/UsherContext.js.map +0 -1
  206. package/dist/cjs/Provider/UsherProvider.d.ts +0 -14
  207. package/dist/cjs/Provider/UsherProvider.d.ts.map +0 -1
  208. package/dist/cjs/Provider/UsherProvider.js +0 -122
  209. package/dist/cjs/Provider/UsherProvider.js.map +0 -1
  210. package/dist/cjs/Provider/index.d.ts +0 -5
  211. package/dist/cjs/Provider/index.d.ts.map +0 -1
  212. package/dist/cjs/Provider/useUsher.d.ts +0 -13
  213. package/dist/cjs/Provider/useUsher.d.ts.map +0 -1
  214. package/dist/cjs/Provider/useUsher.js +0 -31
  215. package/dist/cjs/Provider/useUsher.js.map +0 -1
  216. package/dist/cjs/Reporting/AccessChoice.d.ts +0 -13
  217. package/dist/cjs/Reporting/AccessChoice.d.ts.map +0 -1
  218. package/dist/cjs/Reporting/AccessChoice.js +0 -113
  219. package/dist/cjs/Reporting/AccessChoice.js.map +0 -1
  220. package/dist/cjs/Reporting/AccessFields.d.ts +0 -12
  221. package/dist/cjs/Reporting/AccessFields.d.ts.map +0 -1
  222. package/dist/cjs/Reporting/AccessFields.js +0 -79
  223. package/dist/cjs/Reporting/AccessFields.js.map +0 -1
  224. package/dist/cjs/Reporting/AccessNotice.d.ts +0 -7
  225. package/dist/cjs/Reporting/AccessNotice.d.ts.map +0 -1
  226. package/dist/cjs/Reporting/AccessNotice.js +0 -28
  227. package/dist/cjs/Reporting/AccessNotice.js.map +0 -1
  228. package/dist/cjs/Reporting/ReportErrorDialog.d.ts +0 -9
  229. package/dist/cjs/Reporting/ReportErrorDialog.d.ts.map +0 -1
  230. package/dist/cjs/Reporting/ReportErrorDialog.js +0 -87
  231. package/dist/cjs/Reporting/ReportErrorDialog.js.map +0 -1
  232. package/dist/cjs/Reporting/ReportIssueDialog.d.ts +0 -8
  233. package/dist/cjs/Reporting/ReportIssueDialog.d.ts.map +0 -1
  234. package/dist/cjs/Reporting/ReportIssueDialog.js +0 -81
  235. package/dist/cjs/Reporting/ReportIssueDialog.js.map +0 -1
  236. package/dist/cjs/Reporting/ReportLimits.d.ts +0 -8
  237. package/dist/cjs/Reporting/ReportLimits.d.ts.map +0 -1
  238. package/dist/cjs/Reporting/ReportLimits.js +0 -19
  239. package/dist/cjs/Reporting/ReportLimits.js.map +0 -1
  240. package/dist/cjs/Reporting/ReportSent.d.ts +0 -5
  241. package/dist/cjs/Reporting/ReportSent.d.ts.map +0 -1
  242. package/dist/cjs/Reporting/SentWithReport.d.ts +0 -7
  243. package/dist/cjs/Reporting/SentWithReport.d.ts.map +0 -1
  244. package/dist/cjs/Reporting/SentWithReport.js +0 -40
  245. package/dist/cjs/Reporting/SentWithReport.js.map +0 -1
  246. package/dist/cjs/Reporting/TechnicalDetails.d.ts +0 -9
  247. package/dist/cjs/Reporting/TechnicalDetails.d.ts.map +0 -1
  248. package/dist/cjs/Reporting/TechnicalDetails.js +0 -75
  249. package/dist/cjs/Reporting/TechnicalDetails.js.map +0 -1
  250. package/dist/cjs/Reporting/durationOptions.d.ts +0 -9
  251. package/dist/cjs/Reporting/durationOptions.d.ts.map +0 -1
  252. package/dist/cjs/Reporting/durationOptions.js +0 -29
  253. package/dist/cjs/Reporting/durationOptions.js.map +0 -1
  254. package/dist/cjs/Reporting/formatLocation.d.ts +0 -7
  255. package/dist/cjs/Reporting/formatLocation.d.ts.map +0 -1
  256. package/dist/cjs/Reporting/formatLocation.js +0 -23
  257. package/dist/cjs/Reporting/formatLocation.js.map +0 -1
  258. package/dist/cjs/Reporting/index.d.ts +0 -14
  259. package/dist/cjs/Reporting/index.d.ts.map +0 -1
  260. package/dist/cjs/Reporting/reportValues.d.ts +0 -22
  261. package/dist/cjs/Reporting/reportValues.d.ts.map +0 -1
  262. package/dist/cjs/Reporting/reportValues.js +0 -124
  263. package/dist/cjs/Reporting/reportValues.js.map +0 -1
  264. package/dist/cjs/Reporting/useAccessChoice.d.ts +0 -13
  265. package/dist/cjs/Reporting/useAccessChoice.d.ts.map +0 -1
  266. package/dist/cjs/Reporting/useAccessChoice.js +0 -41
  267. package/dist/cjs/Reporting/useAccessChoice.js.map +0 -1
  268. package/dist/cjs/index.d.ts +0 -8
  269. package/dist/cjs/index.d.ts.map +0 -1
  270. package/dist/cjs/index.js +0 -133
  271. package/dist/cjs/index.js.map +0 -1
  272. package/dist/cjs/package.json +0 -3
  273. package/dist/esm/Buttons/MyIssuesButton.d.ts +0 -14
  274. package/dist/esm/Buttons/MyIssuesButton.d.ts.map +0 -1
  275. package/dist/esm/Buttons/MyIssuesButton.js +0 -73
  276. package/dist/esm/Buttons/MyIssuesButton.js.map +0 -1
  277. package/dist/esm/Buttons/ReportButton.d.ts +0 -8
  278. package/dist/esm/Buttons/ReportButton.d.ts.map +0 -1
  279. package/dist/esm/Buttons/ReportButton.js +0 -32
  280. package/dist/esm/Buttons/ReportButton.js.map +0 -1
  281. package/dist/esm/Buttons/buttonModels.d.ts +0 -10
  282. package/dist/esm/Buttons/buttonModels.d.ts.map +0 -1
  283. package/dist/esm/Buttons/buttonModels.js +0 -41
  284. package/dist/esm/Buttons/buttonModels.js.map +0 -1
  285. package/dist/esm/Buttons/index.d.ts +0 -4
  286. package/dist/esm/Buttons/index.d.ts.map +0 -1
  287. package/dist/esm/Buttons/index.js +0 -4
  288. package/dist/esm/Buttons/index.js.map +0 -1
  289. package/dist/esm/Correlation/CorrelationTracker.d.ts +0 -10
  290. package/dist/esm/Correlation/CorrelationTracker.d.ts.map +0 -1
  291. package/dist/esm/Correlation/CorrelationTracker.js +0 -48
  292. package/dist/esm/Correlation/CorrelationTracker.js.map +0 -1
  293. package/dist/esm/Correlation/index.d.ts +0 -3
  294. package/dist/esm/Correlation/index.d.ts.map +0 -1
  295. package/dist/esm/Correlation/index.js +0 -3
  296. package/dist/esm/Correlation/index.js.map +0 -1
  297. package/dist/esm/Correlation/withCorrelationIdHeader.d.ts +0 -6
  298. package/dist/esm/Correlation/withCorrelationIdHeader.d.ts.map +0 -1
  299. package/dist/esm/Correlation/withCorrelationIdHeader.js +0 -36
  300. package/dist/esm/Correlation/withCorrelationIdHeader.js.map +0 -1
  301. package/dist/esm/Icons.d.ts +0 -4
  302. package/dist/esm/Icons.d.ts.map +0 -1
  303. package/dist/esm/Icons.js +0 -49
  304. package/dist/esm/Icons.js.map +0 -1
  305. package/dist/esm/Issues/IssueView/AccessPanel.d.ts +0 -6
  306. package/dist/esm/Issues/IssueView/AccessPanel.d.ts.map +0 -1
  307. package/dist/esm/Issues/IssueView/AccessPanel.js +0 -122
  308. package/dist/esm/Issues/IssueView/AccessPanel.js.map +0 -1
  309. package/dist/esm/Issues/IssueView/GrantAccessDialog.d.ts +0 -6
  310. package/dist/esm/Issues/IssueView/GrantAccessDialog.d.ts.map +0 -1
  311. package/dist/esm/Issues/IssueView/GrantAccessDialog.js +0 -54
  312. package/dist/esm/Issues/IssueView/GrantAccessDialog.js.map +0 -1
  313. package/dist/esm/Issues/IssueView/IdentityPanel.d.ts +0 -6
  314. package/dist/esm/Issues/IssueView/IdentityPanel.d.ts.map +0 -1
  315. package/dist/esm/Issues/IssueView/IdentityPanel.js +0 -43
  316. package/dist/esm/Issues/IssueView/IdentityPanel.js.map +0 -1
  317. package/dist/esm/Issues/IssueView/IssueActions.d.ts +0 -6
  318. package/dist/esm/Issues/IssueView/IssueActions.d.ts.map +0 -1
  319. package/dist/esm/Issues/IssueView/IssueActions.js +0 -56
  320. package/dist/esm/Issues/IssueView/IssueActions.js.map +0 -1
  321. package/dist/esm/Issues/IssueView/IssueConversationPanel.d.ts +0 -6
  322. package/dist/esm/Issues/IssueView/IssueConversationPanel.d.ts.map +0 -1
  323. package/dist/esm/Issues/IssueView/IssueConversationPanel.js +0 -95
  324. package/dist/esm/Issues/IssueView/IssueConversationPanel.js.map +0 -1
  325. package/dist/esm/Issues/IssueView/IssueHeader.d.ts +0 -7
  326. package/dist/esm/Issues/IssueView/IssueHeader.d.ts.map +0 -1
  327. package/dist/esm/Issues/IssueView/IssueHeader.js +0 -92
  328. package/dist/esm/Issues/IssueView/IssueHeader.js.map +0 -1
  329. package/dist/esm/Issues/IssueView/IssueView.d.ts +0 -7
  330. package/dist/esm/Issues/IssueView/IssueView.d.ts.map +0 -1
  331. package/dist/esm/Issues/IssueView/IssueView.js +0 -83
  332. package/dist/esm/Issues/IssueView/IssueView.js.map +0 -1
  333. package/dist/esm/Issues/IssueView/QuestionBanner.d.ts +0 -5
  334. package/dist/esm/Issues/IssueView/QuestionBanner.d.ts.map +0 -1
  335. package/dist/esm/Issues/IssueView/QuestionBanner.js +0 -22
  336. package/dist/esm/Issues/IssueView/QuestionBanner.js.map +0 -1
  337. package/dist/esm/Issues/IssueView/ReopenIssueDialog.d.ts +0 -6
  338. package/dist/esm/Issues/IssueView/ReopenIssueDialog.d.ts.map +0 -1
  339. package/dist/esm/Issues/IssueView/ReopenIssueDialog.js +0 -32
  340. package/dist/esm/Issues/IssueView/ReopenIssueDialog.js.map +0 -1
  341. package/dist/esm/Issues/IssueView/ShareIdentityDialog.d.ts +0 -6
  342. package/dist/esm/Issues/IssueView/ShareIdentityDialog.d.ts.map +0 -1
  343. package/dist/esm/Issues/IssueView/ShareIdentityDialog.js +0 -30
  344. package/dist/esm/Issues/IssueView/ShareIdentityDialog.js.map +0 -1
  345. package/dist/esm/Issues/IssueView/StatusStrip.d.ts +0 -6
  346. package/dist/esm/Issues/IssueView/StatusStrip.d.ts.map +0 -1
  347. package/dist/esm/Issues/IssueView/StatusStrip.js +0 -29
  348. package/dist/esm/Issues/IssueView/StatusStrip.js.map +0 -1
  349. package/dist/esm/Issues/IssueView/SupportSessions.d.ts +0 -7
  350. package/dist/esm/Issues/IssueView/SupportSessions.d.ts.map +0 -1
  351. package/dist/esm/Issues/IssueView/SupportSessions.js +0 -60
  352. package/dist/esm/Issues/IssueView/SupportSessions.js.map +0 -1
  353. package/dist/esm/Issues/IssueView/index.d.ts +0 -13
  354. package/dist/esm/Issues/IssueView/index.d.ts.map +0 -1
  355. package/dist/esm/Issues/IssueView/index.js +0 -13
  356. package/dist/esm/Issues/IssueView/index.js.map +0 -1
  357. package/dist/esm/Issues/MyIssues/IssueList.d.ts +0 -7
  358. package/dist/esm/Issues/MyIssues/IssueList.d.ts.map +0 -1
  359. package/dist/esm/Issues/MyIssues/IssueList.js +0 -90
  360. package/dist/esm/Issues/MyIssues/IssueList.js.map +0 -1
  361. package/dist/esm/Issues/MyIssues/MyIssuesDialog.d.ts +0 -7
  362. package/dist/esm/Issues/MyIssues/MyIssuesDialog.d.ts.map +0 -1
  363. package/dist/esm/Issues/MyIssues/MyIssuesDialog.js +0 -77
  364. package/dist/esm/Issues/MyIssues/MyIssuesDialog.js.map +0 -1
  365. package/dist/esm/Issues/MyIssues/MyIssuesNavigation.d.ts +0 -21
  366. package/dist/esm/Issues/MyIssues/MyIssuesNavigation.d.ts.map +0 -1
  367. package/dist/esm/Issues/MyIssues/MyIssuesNavigation.js +0 -49
  368. package/dist/esm/Issues/MyIssues/MyIssuesNavigation.js.map +0 -1
  369. package/dist/esm/Issues/MyIssues/index.d.ts +0 -4
  370. package/dist/esm/Issues/MyIssues/index.d.ts.map +0 -1
  371. package/dist/esm/Issues/MyIssues/index.js +0 -4
  372. package/dist/esm/Issues/MyIssues/index.js.map +0 -1
  373. package/dist/esm/Issues/MyIssuesList.d.ts +0 -7
  374. package/dist/esm/Issues/MyIssuesList.d.ts.map +0 -1
  375. package/dist/esm/Issues/MyIssuesList.js +0 -29
  376. package/dist/esm/Issues/MyIssuesList.js.map +0 -1
  377. package/dist/esm/Issues/accessStatus.d.ts +0 -13
  378. package/dist/esm/Issues/accessStatus.d.ts.map +0 -1
  379. package/dist/esm/Issues/accessStatus.js +0 -54
  380. package/dist/esm/Issues/accessStatus.js.map +0 -1
  381. package/dist/esm/Issues/conversationMessages.d.ts +0 -14
  382. package/dist/esm/Issues/conversationMessages.d.ts.map +0 -1
  383. package/dist/esm/Issues/conversationMessages.js +0 -125
  384. package/dist/esm/Issues/conversationMessages.js.map +0 -1
  385. package/dist/esm/Issues/index.d.ts +0 -10
  386. package/dist/esm/Issues/index.d.ts.map +0 -1
  387. package/dist/esm/Issues/index.js +0 -10
  388. package/dist/esm/Issues/index.js.map +0 -1
  389. package/dist/esm/Issues/issueStates.d.ts +0 -12
  390. package/dist/esm/Issues/issueStates.d.ts.map +0 -1
  391. package/dist/esm/Issues/issueStates.js +0 -81
  392. package/dist/esm/Issues/issueStates.js.map +0 -1
  393. package/dist/esm/Issues/sessionActivity.d.ts +0 -8
  394. package/dist/esm/Issues/sessionActivity.d.ts.map +0 -1
  395. package/dist/esm/Issues/sessionActivity.js +0 -37
  396. package/dist/esm/Issues/sessionActivity.js.map +0 -1
  397. package/dist/esm/Issues/useAccessStatus.d.ts +0 -4
  398. package/dist/esm/Issues/useAccessStatus.d.ts.map +0 -1
  399. package/dist/esm/Issues/useAccessStatus.js +0 -28
  400. package/dist/esm/Issues/useAccessStatus.js.map +0 -1
  401. package/dist/esm/Issues/webAddress.d.ts +0 -2
  402. package/dist/esm/Issues/webAddress.d.ts.map +0 -1
  403. package/dist/esm/Issues/webAddress.js +0 -22
  404. package/dist/esm/Issues/webAddress.js.map +0 -1
  405. package/dist/esm/Labels/UsherLabels.d.ts +0 -177
  406. package/dist/esm/Labels/UsherLabels.d.ts.map +0 -1
  407. package/dist/esm/Labels/UsherLabels.js +0 -2
  408. package/dist/esm/Labels/UsherLabels.js.map +0 -1
  409. package/dist/esm/Labels/defaultUsherLabels.d.ts +0 -3
  410. package/dist/esm/Labels/defaultUsherLabels.d.ts.map +0 -1
  411. package/dist/esm/Labels/defaultUsherLabels.js +0 -177
  412. package/dist/esm/Labels/defaultUsherLabels.js.map +0 -1
  413. package/dist/esm/Labels/format.d.ts +0 -2
  414. package/dist/esm/Labels/format.d.ts.map +0 -1
  415. package/dist/esm/Labels/format.js +0 -13
  416. package/dist/esm/Labels/format.js.map +0 -1
  417. package/dist/esm/Labels/index.d.ts +0 -5
  418. package/dist/esm/Labels/index.d.ts.map +0 -1
  419. package/dist/esm/Labels/index.js +0 -5
  420. package/dist/esm/Labels/index.js.map +0 -1
  421. package/dist/esm/Labels/resolveLabels.d.ts +0 -3
  422. package/dist/esm/Labels/resolveLabels.d.ts.map +0 -1
  423. package/dist/esm/Labels/resolveLabels.js +0 -33
  424. package/dist/esm/Labels/resolveLabels.js.map +0 -1
  425. package/dist/esm/Provider/UsherBoundary.d.ts +0 -6
  426. package/dist/esm/Provider/UsherBoundary.d.ts.map +0 -1
  427. package/dist/esm/Provider/UsherBoundary.js +0 -22
  428. package/dist/esm/Provider/UsherBoundary.js.map +0 -1
  429. package/dist/esm/Provider/UsherContext.d.ts +0 -24
  430. package/dist/esm/Provider/UsherContext.d.ts.map +0 -1
  431. package/dist/esm/Provider/UsherContext.js +0 -36
  432. package/dist/esm/Provider/UsherContext.js.map +0 -1
  433. package/dist/esm/Provider/UsherProvider.d.ts +0 -14
  434. package/dist/esm/Provider/UsherProvider.d.ts.map +0 -1
  435. package/dist/esm/Provider/UsherProvider.js +0 -120
  436. package/dist/esm/Provider/UsherProvider.js.map +0 -1
  437. package/dist/esm/Provider/index.d.ts +0 -5
  438. package/dist/esm/Provider/index.d.ts.map +0 -1
  439. package/dist/esm/Provider/index.js +0 -5
  440. package/dist/esm/Provider/index.js.map +0 -1
  441. package/dist/esm/Provider/useUsher.d.ts +0 -13
  442. package/dist/esm/Provider/useUsher.d.ts.map +0 -1
  443. package/dist/esm/Provider/useUsher.js +0 -29
  444. package/dist/esm/Provider/useUsher.js.map +0 -1
  445. package/dist/esm/Reporting/AccessChoice.d.ts +0 -13
  446. package/dist/esm/Reporting/AccessChoice.d.ts.map +0 -1
  447. package/dist/esm/Reporting/AccessChoice.js +0 -106
  448. package/dist/esm/Reporting/AccessChoice.js.map +0 -1
  449. package/dist/esm/Reporting/AccessFields.d.ts +0 -12
  450. package/dist/esm/Reporting/AccessFields.d.ts.map +0 -1
  451. package/dist/esm/Reporting/AccessFields.js +0 -77
  452. package/dist/esm/Reporting/AccessFields.js.map +0 -1
  453. package/dist/esm/Reporting/AccessNotice.d.ts +0 -7
  454. package/dist/esm/Reporting/AccessNotice.d.ts.map +0 -1
  455. package/dist/esm/Reporting/AccessNotice.js +0 -26
  456. package/dist/esm/Reporting/AccessNotice.js.map +0 -1
  457. package/dist/esm/Reporting/ReportErrorDialog.d.ts +0 -9
  458. package/dist/esm/Reporting/ReportErrorDialog.d.ts.map +0 -1
  459. package/dist/esm/Reporting/ReportErrorDialog.js +0 -85
  460. package/dist/esm/Reporting/ReportErrorDialog.js.map +0 -1
  461. package/dist/esm/Reporting/ReportIssueDialog.d.ts +0 -8
  462. package/dist/esm/Reporting/ReportIssueDialog.d.ts.map +0 -1
  463. package/dist/esm/Reporting/ReportIssueDialog.js +0 -79
  464. package/dist/esm/Reporting/ReportIssueDialog.js.map +0 -1
  465. package/dist/esm/Reporting/ReportLimits.d.ts +0 -8
  466. package/dist/esm/Reporting/ReportLimits.d.ts.map +0 -1
  467. package/dist/esm/Reporting/ReportLimits.js +0 -17
  468. package/dist/esm/Reporting/ReportLimits.js.map +0 -1
  469. package/dist/esm/Reporting/ReportSent.d.ts +0 -5
  470. package/dist/esm/Reporting/ReportSent.d.ts.map +0 -1
  471. package/dist/esm/Reporting/ReportSent.js +0 -2
  472. package/dist/esm/Reporting/ReportSent.js.map +0 -1
  473. package/dist/esm/Reporting/SentWithReport.d.ts +0 -7
  474. package/dist/esm/Reporting/SentWithReport.d.ts.map +0 -1
  475. package/dist/esm/Reporting/SentWithReport.js +0 -38
  476. package/dist/esm/Reporting/SentWithReport.js.map +0 -1
  477. package/dist/esm/Reporting/TechnicalDetails.d.ts +0 -9
  478. package/dist/esm/Reporting/TechnicalDetails.d.ts.map +0 -1
  479. package/dist/esm/Reporting/TechnicalDetails.js +0 -73
  480. package/dist/esm/Reporting/TechnicalDetails.js.map +0 -1
  481. package/dist/esm/Reporting/durationOptions.d.ts +0 -9
  482. package/dist/esm/Reporting/durationOptions.d.ts.map +0 -1
  483. package/dist/esm/Reporting/durationOptions.js +0 -27
  484. package/dist/esm/Reporting/durationOptions.js.map +0 -1
  485. package/dist/esm/Reporting/formatLocation.d.ts +0 -7
  486. package/dist/esm/Reporting/formatLocation.d.ts.map +0 -1
  487. package/dist/esm/Reporting/formatLocation.js +0 -21
  488. package/dist/esm/Reporting/formatLocation.js.map +0 -1
  489. package/dist/esm/Reporting/index.d.ts +0 -14
  490. package/dist/esm/Reporting/index.d.ts.map +0 -1
  491. package/dist/esm/Reporting/index.js +0 -14
  492. package/dist/esm/Reporting/index.js.map +0 -1
  493. package/dist/esm/Reporting/reportValues.d.ts +0 -22
  494. package/dist/esm/Reporting/reportValues.d.ts.map +0 -1
  495. package/dist/esm/Reporting/reportValues.js +0 -116
  496. package/dist/esm/Reporting/reportValues.js.map +0 -1
  497. package/dist/esm/Reporting/useAccessChoice.d.ts +0 -13
  498. package/dist/esm/Reporting/useAccessChoice.d.ts.map +0 -1
  499. package/dist/esm/Reporting/useAccessChoice.js +0 -39
  500. package/dist/esm/Reporting/useAccessChoice.js.map +0 -1
  501. package/dist/esm/index.d.ts +0 -8
  502. package/dist/esm/index.d.ts.map +0 -1
  503. package/dist/esm/index.js +0 -48
  504. package/dist/esm/index.js.map +0 -1
  505. package/dist/esm/package.json +0 -3
  506. package/index.ts +0 -10
  507. package/styles.css +0 -320
package/README.md CHANGED
@@ -1,72 +1,3 @@
1
- # @cratis/showrunner.usher.react
1
+ # Temporary Holding Version
2
2
 
3
- React components for Usher, the Showrunner support part: report a problem, report this error, and the my issues side
4
- sheet with each issue's conversation. Built on `@cratis/components` and the generated proxies in
5
- `@cratis/showrunner.usher`. How to use it: [Documentation/Usher/react.md](../../../Documentation/Usher/react.md).
6
-
7
- ## Component hierarchy
8
-
9
- ```
10
- UsherProvider provides UsherContext, wraps ArcContext for correlation tracking, renders the dialogs once
11
- ├── ReportIssueDialog CommandDialog<ReportIssue>
12
- │ ├── SentWithReport what is sent along: location, version, recent requests
13
- │ └── AccessFields share identity / grant access / duration, with AccessNotice
14
- ├── ReportErrorDialog CommandDialog<ReportError>
15
- │ ├── TechnicalDetails collapsed <details>: type, correlation id, stack frames
16
- │ ├── SentWithReport
17
- │ └── AccessFields
18
- └── MyIssuesDialog Dialog placement='end', 720px
19
- ├── IssueList DataTableForObservableQuery<MyIssues>
20
- └── IssueView also exported on its own
21
- ├── IssueHeader, StatusStrip, QuestionBanner
22
- ├── IssueConversationPanel ChatConversation; AnswerQuestion or AddDetails
23
- ├── IdentityPanel ShareIdentityDialog
24
- ├── AccessPanel GrantAccessDialog, revoke with confirmation, SupportSessions
25
- └── IssueActions ReopenIssueDialog, withdraw with confirmation
26
- ReportButton, MyIssuesButton open the dialogs through useUsher()
27
- ```
28
-
29
- ## Architecture decisions
30
-
31
- - **One provider, dialogs rendered once.** `UsherProvider` owns the `useDialog` wrappers; the buttons and `useUsher()`
32
- only call into `UsherContext`. The location of the caller is taken with `useSliceContext()` where `useUsher()` is
33
- called and passed to the dialog, because the dialogs render at the provider, outside the caller's slice scope.
34
- - **Correlation tracking through the HTTP headers callback.** Arc has no global observer of command or query results,
35
- but Arc React hands each command and snapshot query the `httpHeadersCallback` of the nearest `ArcContext`. The
36
- provider wraps it to add an `X-Correlation-ID` to every request and remember it (`Correlation/`). Arc's backend uses
37
- the id a request carries. Observable queries go over Arc's shared hub connection and are not tracked.
38
- - **`UsherBoundary` keeps Usher out of what it reports.** Usher's own components run with the untracked `ArcContext`
39
- and inside a `<Slice>` boundary, so its requests are not sent with a report and its proxies do not change the slice
40
- context of the application around them.
41
- - **Granting access forces sharing identity.** `useAccessChoice` follows the form through `onFieldChange` and forces
42
- `shareIdentity` through `currentValues`. `shareIdentity` is left out of `initialValues`, because the form merges
43
- `initialValues` over `currentValues`.
44
-
45
- ## State
46
-
47
- Decisions live in pure, specified modules; the components render and wire events:
48
-
49
- | Module | Decides |
50
- | --- | --- |
51
- | `Reporting/AccessChoice.ts` | access choice transitions, forced identity, until when access lasts |
52
- | `Reporting/reportValues.ts` | the initial values of a report, error details from what was thrown |
53
- | `Issues/issueStates.ts` | state badges, closed states, status strip step |
54
- | `Issues/MyIssuesList.ts` | waiting count, closed filter, fix released |
55
- | `Issues/conversationMessages.ts` | chat authors and message bodies |
56
- | `Issues/accessStatus.ts` | whether support may sign in, against the clock |
57
- | `Issues/MyIssues/MyIssuesNavigation.ts` | list or issue, show closed |
58
- | `Buttons/buttonModels.ts` | text, tooltip and accessible name of the buttons |
59
- | `Labels/` | English defaults, deep overrides, placeholders |
60
-
61
- ## CSS conventions
62
-
63
- One stylesheet, `styles.css`, exported as `@cratis/showrunner.usher.react/styles`; the build has no CSS pipeline, so
64
- components do not import CSS. Classes are prefixed `usher-` with BEM-like element names, and every color, border and
65
- radius comes from the `--cratis-*` tokens. State is styled through `data-*` attributes (`data-highlighted`,
66
- `data-reached`, `data-current`).
67
-
68
- ## Extending
69
-
70
- - A new text: add it to `UsherLabels` and `defaultUsherLabels`; every component reads labels from `UsherContext`.
71
- - A new conversation entry kind: add its sentence to `ConversationEventLabels` and map it in `conversationMessages.ts`.
72
- - A new dialog: render its `useDialog` wrapper in `UsherProvider` and add an opener to `UsherContextValue` and `useUsher`.
3
+ This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
package/package.json CHANGED
@@ -1,85 +1,6 @@
1
1
  {
2
- "type": "module",
3
- "name": "@cratis/showrunner.usher.react",
4
- "version": "0.0.0-bootstrap.0",
5
- "description": "React components for Usher — the Showrunner support part for issue reporting and support conversations, built on Cratis Arc and Cratis Components.",
6
- "keywords": [
7
- "cratis",
8
- "showrunner",
9
- "usher",
10
- "support",
11
- "arc",
12
- "react",
13
- "components"
14
- ],
15
- "homepage": "https://github.com/Cratis/Showrunner",
16
- "author": "Cratis",
17
- "license": "MIT",
18
- "repository": {
19
- "type": "git",
20
- "url": "git+https://github.com/Cratis/Showrunner.git"
21
- },
22
- "publishConfig": {
23
- "access": "public"
24
- },
25
- "files": [
26
- "dist",
27
- "styles.css",
28
- "**/*.ts",
29
- "**/*.tsx",
30
- "!**/for_*/**",
31
- "!**/given/**",
32
- "!**/*.tsbuildinfo"
33
- ],
34
- "main": "dist/cjs/index.js",
35
- "module": "dist/esm/index.js",
36
- "types": "dist/esm/index.d.ts",
37
- "exports": {
38
- "./package.json": "./package.json",
39
- ".": {
40
- "import": {
41
- "types": "./dist/esm/index.d.ts",
42
- "default": "./dist/esm/index.js"
43
- },
44
- "require": {
45
- "types": "./dist/cjs/index.d.ts",
46
- "default": "./dist/cjs/index.js"
47
- }
48
- },
49
- "./styles": "./styles.css"
50
- },
51
- "scripts": {
52
- "prepare": "yarn g:build",
53
- "clean": "yarn g:clean",
54
- "compile": "yarn g:compile",
55
- "build": "yarn g:build",
56
- "lint": "yarn g:lint",
57
- "lint:ci": "yarn g:lint:ci",
58
- "test": "yarn g:test",
59
- "test:watch": "yarn g:test:watch",
60
- "ci": "yarn g:ci",
61
- "up": "yarn g:up"
62
- },
63
- "dependencies": {
64
- "@cratis/showrunner.usher": "0.0.0-bootstrap.0"
65
- },
66
- "devDependencies": {
67
- "@cratis/arc": "22.146.0",
68
- "@cratis/arc.react": "22.146.0",
69
- "@cratis/components": "4.38.0",
70
- "@cratis/fundamentals": "7.27.0",
71
- "react": "^19.3.1",
72
- "react-dom": "^19.3.1",
73
- "reflect-metadata": "0.2.2"
74
- },
75
- "peerDependencies": {
76
- "@cratis/arc": "^22.146.0",
77
- "@cratis/arc.react": "^22.146.0",
78
- "@cratis/components": "^4.38.0",
79
- "@cratis/fundamentals": "^7.27.0",
80
- "react": "^19.0.0"
81
- },
82
- "sideEffects": [
83
- "*.css"
84
- ]
2
+ "name": "@cratis/showrunner.usher.react",
3
+ "version": "0.0.0-stage",
4
+ "stub": true,
5
+ "description": "Temporary package placeholder for staged publishing"
85
6
  }
@@ -1,78 +0,0 @@
1
- // Copyright (c) Cratis. All rights reserved.
2
- // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
-
4
- import { Button, IconButton } from '@cratis/components/Common';
5
- import { Badge } from '@cratis/components/Display';
6
- import { MyIssues } from '@cratis/showrunner.usher';
7
- import { InboxIcon } from '../Icons.js';
8
- import { waitingCount } from '../Issues/MyIssuesList.js';
9
- import { UsherBoundary } from '../Provider/UsherBoundary.js';
10
- import { useUsher } from '../Provider/useUsher.js';
11
- import { myIssuesButtonModel, UsherButtonSize } from './buttonModels.js';
12
-
13
- /**
14
- * Props for {@link MyIssuesButton}.
15
- */
16
- export interface MyIssuesButtonProps {
17
- /** `large` shows the icon and the text; `small` shows the icon, with the text as tooltip and accessible name. Defaults to `large`. */
18
- size?: UsherButtonSize;
19
-
20
- /** Additional class name for the button. */
21
- className?: string;
22
- }
23
-
24
- /**
25
- * Opens the my issues side sheet. A badge counts the issues support waits for the user on, and the accessible name
26
- * says how many.
27
- */
28
- export const MyIssuesButton = (props: MyIssuesButtonProps) => {
29
- const usher = useUsher();
30
-
31
- return (
32
- <UsherBoundary>
33
- <MyIssuesButtonContent {...props} onOpen={usher.showMyIssues} />
34
- </UsherBoundary>
35
- );
36
- };
37
-
38
- const MyIssuesButtonContent = ({ size = 'large', className, onOpen }: MyIssuesButtonProps & { onOpen: () => void }) => {
39
- const usher = useUsher();
40
- const [result] = MyIssues.use();
41
-
42
- return <MyIssuesButtonView size={size} className={className} waiting={waitingCount(result.data ?? [])} labels={usher.labels} onOpen={onOpen} />;
43
- };
44
-
45
- /**
46
- * Props for {@link MyIssuesButtonView}.
47
- */
48
- export interface MyIssuesButtonViewProps extends MyIssuesButtonProps {
49
- /** How many issues support waits for the user on. */
50
- waiting: number;
51
-
52
- /** The labels to show. */
53
- labels: ReturnType<typeof useUsher>['labels'];
54
-
55
- /** Opens the my issues side sheet. */
56
- onOpen: () => void;
57
- }
58
-
59
- /**
60
- * Renders the my issues button for a given number of issues support waits for the user on.
61
- */
62
- export const MyIssuesButtonView = ({ size = 'large', className, waiting, labels, onOpen }: MyIssuesButtonViewProps) => {
63
- const model = myIssuesButtonModel(size, waiting, labels);
64
- const badge = waiting > 0 && (
65
- <span className='usher-my-issues-button__badge' aria-hidden='true'>
66
- <Badge value={waiting} severity='warn' size='small' />
67
- </span>
68
- );
69
-
70
- return (
71
- <span className={['usher-my-issues-button', className].filter(Boolean).join(' ')} data-size={size}>
72
- {size === 'small'
73
- ? <IconButton variant='ghost' icon={<InboxIcon />} aria-label={model.accessibleName} tooltip={model.tooltip} onClick={onOpen} />
74
- : <Button variant='outline' icon={<InboxIcon />} label={model.text} aria-label={model.accessibleName} onClick={onOpen} />}
75
- {badge}
76
- </span>
77
- );
78
- };
@@ -1,51 +0,0 @@
1
- // Copyright (c) Cratis. All rights reserved.
2
- // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
-
4
- import { Button, IconButton } from '@cratis/components/Common';
5
- import { BugIcon } from '../Icons.js';
6
- import { useUsher } from '../Provider/useUsher.js';
7
- import { reportButtonModel, UsherButtonSize } from './buttonModels.js';
8
-
9
- /**
10
- * Props for {@link ReportButton}.
11
- */
12
- export interface ReportButtonProps {
13
- /** `large` shows the icon and the text; `small` shows the icon, with the text as tooltip and accessible name. Defaults to `large`. */
14
- size?: UsherButtonSize;
15
-
16
- /** The error to report: `ErrorDetails` from `@cratis/showrunner.usher`, or anything thrown. The button reports a problem described by hand when not given. */
17
- error?: unknown;
18
-
19
- /** Additional class name for the button. */
20
- className?: string;
21
- }
22
-
23
- /**
24
- * Opens the report a problem dialog, or the report this error dialog when given an error, with where in the
25
- * application the button is.
26
- */
27
- export const ReportButton = ({ size = 'large', error, className }: ReportButtonProps) => {
28
- const usher = useUsher();
29
- const reportsError = error !== undefined;
30
- const model = reportButtonModel(size, reportsError, usher.labels);
31
- const report = () => reportsError ? usher.reportError(error) : usher.reportIssue();
32
-
33
- return size === 'small'
34
- ? (
35
- <IconButton
36
- className={className}
37
- variant='ghost'
38
- icon={<BugIcon />}
39
- aria-label={model.accessibleName}
40
- tooltip={model.tooltip}
41
- onClick={report} />
42
- )
43
- : (
44
- <Button
45
- className={className}
46
- variant='outline'
47
- icon={<BugIcon />}
48
- label={model.text}
49
- onClick={report} />
50
- );
51
- };
@@ -1,55 +0,0 @@
1
- // Copyright (c) Cratis. All rights reserved.
2
- // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
-
4
- import { format, UsherLabels } from '../Labels/index.js';
5
-
6
- /**
7
- * The sizes of the Usher buttons: `large` shows the icon and the text; `small` shows the icon, with the text as the
8
- * tooltip and the accessible name.
9
- */
10
- export type UsherButtonSize = 'large' | 'small';
11
-
12
- /**
13
- * What an Usher button shows and announces.
14
- */
15
- export interface ButtonModel {
16
- /** The visible text; empty for a small button. */
17
- readonly text: string;
18
-
19
- /** The accessible name. */
20
- readonly accessibleName: string;
21
-
22
- /** The tooltip; empty for a large button, whose text says it all. */
23
- readonly tooltip: string;
24
- }
25
-
26
- /**
27
- * Gets what the report button shows and announces.
28
- * @param size The {@link UsherButtonSize}.
29
- * @param reportsError Whether the button reports an error rather than a problem described by hand.
30
- * @param labels The labels to show.
31
- * @returns The {@link ButtonModel}.
32
- */
33
- export function reportButtonModel(size: UsherButtonSize, reportsError: boolean, labels: UsherLabels): ButtonModel {
34
- const label = reportsError ? labels.reportButton.reportError : labels.reportButton.reportProblem;
35
- return modelFor(size, label, label);
36
- }
37
-
38
- /**
39
- * Gets what the my issues button shows and announces.
40
- * @param size The {@link UsherButtonSize}.
41
- * @param waiting How many issues support waits for the user on.
42
- * @param labels The labels to show.
43
- * @returns The {@link ButtonModel}.
44
- */
45
- export function myIssuesButtonModel(size: UsherButtonSize, waiting: number, labels: UsherLabels): ButtonModel {
46
- const label = labels.myIssuesButton.label;
47
- const accessibleName = waiting > 0 ? `${label}, ${format(labels.myIssuesButton.waiting, { count: waiting })}` : label;
48
- return modelFor(size, label, accessibleName);
49
- }
50
-
51
- function modelFor(size: UsherButtonSize, label: string, accessibleName: string): ButtonModel {
52
- return size === 'small'
53
- ? { text: '', accessibleName, tooltip: accessibleName }
54
- : { text: label, accessibleName, tooltip: '' };
55
- }
package/Buttons/index.ts DELETED
@@ -1,6 +0,0 @@
1
- // Copyright (c) Cratis. All rights reserved.
2
- // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
-
4
- export * from './buttonModels.js';
5
- export * from './MyIssuesButton.js';
6
- export * from './ReportButton.js';
@@ -1,51 +0,0 @@
1
- // Copyright (c) Cratis. All rights reserved.
2
- // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
-
4
- import { Guid } from '@cratis/fundamentals';
5
-
6
- /**
7
- * Keeps the correlation ids of the last few Arc commands and queries, so a report can carry them.
8
- */
9
- export class CorrelationTracker {
10
- private _correlationIds: Guid[] = [];
11
-
12
- /**
13
- * Initializes a new instance of {@link CorrelationTracker}.
14
- * @param capacity How many correlation ids to keep; the oldest is dropped when one more is tracked.
15
- */
16
- constructor(readonly capacity: number = 5) {
17
- }
18
-
19
- /**
20
- * Gets the correlation ids kept, oldest first.
21
- */
22
- get correlationIds(): Guid[] {
23
- return [...this._correlationIds];
24
- }
25
-
26
- /**
27
- * Tracks a correlation id. A correlation id already kept moves to the end instead of being kept twice; an
28
- * empty one is ignored.
29
- * @param correlationId The correlation id, as a {@link Guid} or its string form.
30
- */
31
- track(correlationId: Guid | string): void {
32
- const parsed = typeof correlationId === 'string' ? parseGuid(correlationId) : correlationId;
33
- if (!parsed || parsed.equals(Guid.empty)) {
34
- return;
35
- }
36
-
37
- this._correlationIds = [...this._correlationIds.filter(existing => !existing.equals(parsed)), parsed]
38
- .slice(-Math.max(this.capacity, 0));
39
- }
40
-
41
- /**
42
- * Forgets every correlation id kept.
43
- */
44
- clear(): void {
45
- this._correlationIds = [];
46
- }
47
- }
48
-
49
- function parseGuid(value: string): Guid | undefined {
50
- return Guid.isGuid(value) ? Guid.parse(value) : undefined;
51
- }
@@ -1,5 +0,0 @@
1
- // Copyright (c) Cratis. All rights reserved.
2
- // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
-
4
- export * from './CorrelationTracker.js';
5
- export * from './withCorrelationIdHeader.js';
@@ -1,44 +0,0 @@
1
- // Copyright (c) Cratis. All rights reserved.
2
- // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
-
4
- import { GetHttpHeaders } from '@cratis/arc';
5
- import { Guid } from '@cratis/fundamentals';
6
- import { CorrelationTracker } from './CorrelationTracker.js';
7
-
8
- /**
9
- * The HTTP header Arc reads the correlation id of a command or query from, unless the backend configures another.
10
- */
11
- export const defaultCorrelationIdHeader = 'X-Correlation-ID';
12
-
13
- /**
14
- * Wraps the HTTP headers callback Arc calls for every command and query request, so each request carries a
15
- * correlation id the tracker knows.
16
- * @remarks
17
- * Arc uses the correlation id a request carries in its correlation id header, so the id tracked is the id the
18
- * backend records for the command or query. A correlation id the headers already carry is kept and tracked;
19
- * otherwise a new one is added.
20
- * @param headersCallback The callback to wrap; nothing for none.
21
- * @param tracker The {@link CorrelationTracker} to track the correlation ids in.
22
- * @param header The name of the correlation id header.
23
- * @param createCorrelationId Creates a new correlation id.
24
- * @returns The wrapping callback.
25
- */
26
- export function withCorrelationIdHeader(
27
- headersCallback: GetHttpHeaders | undefined,
28
- tracker: CorrelationTracker,
29
- header: string = defaultCorrelationIdHeader,
30
- createCorrelationId: () => Guid = () => Guid.create()): GetHttpHeaders {
31
- return () => {
32
- const headers = new Headers(headersCallback?.() ?? {});
33
- const existing = headers.get(header);
34
- const correlationId = existing && Guid.isGuid(existing) ? existing : createCorrelationId().toString();
35
- headers.set(header, correlationId);
36
- tracker.track(correlationId);
37
-
38
- const record: Record<string, string> = {};
39
- headers.forEach((value, name) => {
40
- record[name] = value;
41
- });
42
- return record;
43
- };
44
- }
package/Icons.tsx DELETED
@@ -1,29 +0,0 @@
1
- // Copyright (c) Cratis. All rights reserved.
2
- // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
-
4
- /**
5
- * The bug icon of the report button. Decorative: the button carries the accessible name.
6
- */
7
- export const BugIcon = () => (
8
- <svg className='usher-icon' viewBox='0 0 24 24' width='1em' height='1em' aria-hidden='true' focusable='false'>
9
- <path fill='currentColor' d='M20 8h-2.81a5.985 5.985 0 0 0-1.82-1.96L17 4.41 15.59 3l-2.17 2.17a6.002 6.002 0 0 0-2.83 0L8.41 3 7 4.41l1.62 1.63C7.88 6.55 7.26 7.22 6.81 8H4v2h2.09c-.05.33-.09.66-.09 1v1H4v2h2v1c0 .34.04.67.09 1H4v2h2.81c1.04 1.79 2.97 3 5.19 3s4.15-1.21 5.19-3H20v-2h-2.09c.05-.33.09-.66.09-1v-1h2v-2h-2v-1c0-.34-.04-.67-.09-1H20V8zm-6 8h-4v-2h4v2zm0-4h-4v-2h4v2z' />
10
- </svg>
11
- );
12
-
13
- /**
14
- * The inbox icon of the my issues button. Decorative: the button carries the accessible name.
15
- */
16
- export const InboxIcon = () => (
17
- <svg className='usher-icon' viewBox='0 0 24 24' width='1em' height='1em' aria-hidden='true' focusable='false'>
18
- <path fill='currentColor' d='M19 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2zm0 12h-4a3 3 0 0 1-6 0H5V5h14v10z' />
19
- </svg>
20
- );
21
-
22
- /**
23
- * The back arrow of the issue view. Decorative: the button carries the accessible name.
24
- */
25
- export const BackIcon = () => (
26
- <svg className='usher-icon' viewBox='0 0 24 24' width='1em' height='1em' aria-hidden='true' focusable='false'>
27
- <path fill='currentColor' d='M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z' />
28
- </svg>
29
- );
@@ -1,85 +0,0 @@
1
- // Copyright (c) Cratis. All rights reserved.
2
- // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
-
4
- import { DialogButtons, DialogResult, useConfirmationDialog, useDialog } from '@cratis/arc.react/dialogs';
5
- import { Button } from '@cratis/components/Common';
6
- import { toastCommandResult } from '@cratis/components/Notifications';
7
- import { IssueConversation, IssueState, RevokeAccess } from '@cratis/showrunner.usher';
8
- import { useId, useState } from 'react';
9
- import { format } from '../../Labels/index.js';
10
- import { useUsherContext } from '../../Provider/UsherContext.js';
11
- import { formatTime } from '../../Reporting/AccessChoice.js';
12
- import { AccessStatus } from '../accessStatus.js';
13
- import { useAccessStatus } from '../useAccessStatus.js';
14
- import { GrantAccessDialog } from './GrantAccessDialog.js';
15
- import { SupportSessions } from './SupportSessions.js';
16
-
17
- /**
18
- * Props for {@link AccessPanel}.
19
- */
20
- export interface AccessPanelProps {
21
- /** The issue. */
22
- issue: IssueConversation;
23
- }
24
-
25
- /**
26
- * Shows whether support may sign in as the reporter, lets them grant or revoke it, highlights support's pending
27
- * request, and lists the sessions in which support signed in.
28
- */
29
- export const AccessPanel = ({ issue }: AccessPanelProps) => {
30
- const { labels, locale } = useUsherContext();
31
- const headingId = useId();
32
- const [GrantDialog, showGrantDialog] = useDialog(GrantAccessDialog);
33
- const [confirm] = useConfirmationDialog();
34
- const [revokeAccess] = RevokeAccess.use();
35
- const [requestDismissed, setRequestDismissed] = useState(false);
36
- const [status] = useAccessStatus(issue.access);
37
- const isWithdrawn = issue.state === IssueState.withdrawn;
38
- const showsRequest = status === AccessStatus.requested && !requestDismissed && !isWithdrawn;
39
- const validUntil = issue.access?.validUntil instanceof Date ? issue.access.validUntil : new Date(issue.access?.validUntil);
40
-
41
- const heading = status === AccessStatus.granted
42
- ? labels.accessPanel.grantedHeading
43
- : showsRequest ? labels.accessPanel.requestedHeading : labels.accessPanel.notGrantedHeading;
44
-
45
- const revoke = async () => {
46
- const answer = await confirm(labels.accessPanel.revokeTitle, labels.accessPanel.revokeMessage, DialogButtons.YesNo);
47
- if (answer !== DialogResult.Yes) {
48
- return;
49
- }
50
-
51
- revokeAccess.issueId = issue.id;
52
- toastCommandResult(await revokeAccess.execute(), { showSuccess: false });
53
- };
54
-
55
- const grant = () => void showGrantDialog({ issueId: issue.id });
56
-
57
- return (
58
- <section className='usher-panel' data-highlighted={showsRequest || undefined} aria-labelledby={headingId}>
59
- <h4 id={headingId} className='usher-panel__heading'>{heading}</h4>
60
- {status === AccessStatus.granted && (
61
- <>
62
- <p className='usher-panel__text'>{format(labels.accessPanel.grantedUntil, { time: formatTime(validUntil, locale) })}</p>
63
- <Button variant='outline' tone='critical' size='small' label={labels.accessPanel.revoke} onClick={() => void revoke()} />
64
- </>
65
- )}
66
- {showsRequest && (
67
- <>
68
- <p className='usher-panel__text'>{format(labels.accessPanel.requestReason, { reason: issue.access.request.reason })}</p>
69
- <div className='usher-panel__actions'>
70
- <Button variant='solid' tone='accent' size='small' label={labels.accessPanel.grant} onClick={grant} />
71
- <Button variant='ghost' size='small' label={labels.accessPanel.notNow} onClick={() => setRequestDismissed(true)} />
72
- </div>
73
- </>
74
- )}
75
- {status !== AccessStatus.granted && !showsRequest && (
76
- <>
77
- <p className='usher-panel__text'>{labels.accessPanel.notGranted}</p>
78
- {!isWithdrawn && <Button variant='outline' size='small' label={labels.accessPanel.grant} onClick={grant} />}
79
- </>
80
- )}
81
- <SupportSessions sessions={issue.access?.sessions ?? []} entries={issue.entries ?? []} />
82
- <GrantDialog />
83
- </section>
84
- );
85
- };
@@ -1,56 +0,0 @@
1
- // Copyright (c) Cratis. All rights reserved.
2
- // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
-
4
- import { CommandDialog } from '@cratis/components/CommandDialog';
5
- import { DropdownField } from '@cratis/components/CommandForm';
6
- import { DialogInitialFocus } from '@cratis/components/Dialogs';
7
- import { Guid } from '@cratis/fundamentals';
8
- import { AccessDuration, GrantAccess } from '@cratis/showrunner.usher';
9
- import { useId, useState } from 'react';
10
- import { useUsherLabels } from '../../Provider/UsherContext.js';
11
- import { AccessNotice } from '../../Reporting/AccessNotice.js';
12
- import { durationOptions } from '../../Reporting/durationOptions.js';
13
-
14
- /**
15
- * Props for {@link GrantAccessDialog}.
16
- */
17
- export interface GrantAccessDialogProps {
18
- /** The issue. */
19
- issueId: Guid;
20
- }
21
-
22
- /**
23
- * Lets the reporter grant support access to sign in as them on an issue for a while, stating until when.
24
- */
25
- export const GrantAccessDialog = ({ issueId }: GrantAccessDialogProps) => {
26
- const labels = useUsherLabels();
27
- const noticeId = useId();
28
- const [duration, setDuration] = useState(AccessDuration.oneDay);
29
-
30
- return (
31
- <CommandDialog<GrantAccess>
32
- command={GrantAccess}
33
- title={labels.accessPanel.grantTitle}
34
- okLabel={labels.accessPanel.grantConfirm}
35
- cancelLabel={labels.common.cancel}
36
- closeAriaLabel={labels.common.close}
37
- initialFocus={DialogInitialFocus.Content}
38
- initialValues={{ issueId, accessDuration: AccessDuration.oneDay }}
39
- onFieldChange={(_command, fieldName, _oldValue, newValue) => {
40
- if (fieldName === 'accessDuration') {
41
- setDuration(Number(newValue) as AccessDuration);
42
- }
43
- }}>
44
- <div className='usher-report-form'>
45
- <DropdownField<GrantAccess>
46
- value={command => command.accessDuration}
47
- title={labels.access.duration}
48
- aria-describedby={noticeId}
49
- options={durationOptions(labels)}
50
- optionValue='value'
51
- optionLabel='label' />
52
- <AccessNotice id={noticeId} duration={duration} />
53
- </div>
54
- </CommandDialog>
55
- );
56
- };