@flightctl/ui-components 0.7.2 → 0.8.0-rc1

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 (408) hide show
  1. package/dist/src/components/DetailsPage/DetailsPageActions.d.ts +1 -1
  2. package/dist/src/components/DetailsPage/DetailsPageActions.d.ts.map +1 -1
  3. package/dist/src/components/DetailsPage/DetailsPageActions.js +1 -1
  4. package/dist/src/components/DetailsPage/DetailsPageActions.js.map +1 -1
  5. package/dist/src/components/Device/AddDeviceModal/AddDeviceModal.d.ts.map +1 -1
  6. package/dist/src/components/Device/AddDeviceModal/AddDeviceModal.js +18 -14
  7. package/dist/src/components/Device/AddDeviceModal/AddDeviceModal.js.map +1 -1
  8. package/dist/src/components/Device/DeviceDetails/DeviceDetailsPage.d.ts.map +1 -1
  9. package/dist/src/components/Device/DeviceDetails/DeviceDetailsPage.js +10 -11
  10. package/dist/src/components/Device/DeviceDetails/DeviceDetailsPage.js.map +1 -1
  11. package/dist/src/components/Device/DeviceDetails/DeviceDetailsTab.d.ts.map +1 -1
  12. package/dist/src/components/Device/DeviceDetails/DeviceDetailsTab.js +31 -10
  13. package/dist/src/components/Device/DeviceDetails/DeviceDetailsTab.js.map +1 -1
  14. package/dist/src/components/Device/DevicesPage/DecommissionedDevicesTable.js +2 -2
  15. package/dist/src/components/Device/DevicesPage/DecommissionedDevicesTable.js.map +1 -1
  16. package/dist/src/components/Device/DevicesPage/EnrolledDevicesTable.js +2 -2
  17. package/dist/src/components/Device/DevicesPage/EnrolledDevicesTable.js.map +1 -1
  18. package/dist/src/components/Device/EditDeviceWizard/EditDeviceWizard.d.ts.map +1 -1
  19. package/dist/src/components/Device/EditDeviceWizard/EditDeviceWizard.js +4 -2
  20. package/dist/src/components/Device/EditDeviceWizard/EditDeviceWizard.js.map +1 -1
  21. package/dist/src/components/Device/EditDeviceWizard/deviceSpecUtils.d.ts.map +1 -1
  22. package/dist/src/components/Device/EditDeviceWizard/deviceSpecUtils.js +29 -1
  23. package/dist/src/components/Device/EditDeviceWizard/deviceSpecUtils.js.map +1 -1
  24. package/dist/src/components/Device/EditDeviceWizard/steps/ApplicationImageForm.d.ts +2 -1
  25. package/dist/src/components/Device/EditDeviceWizard/steps/ApplicationImageForm.d.ts.map +1 -1
  26. package/dist/src/components/Device/EditDeviceWizard/steps/ApplicationImageForm.js +6 -5
  27. package/dist/src/components/Device/EditDeviceWizard/steps/ApplicationImageForm.js.map +1 -1
  28. package/dist/src/components/Device/EditDeviceWizard/steps/ApplicationInlineForm.d.ts +3 -2
  29. package/dist/src/components/Device/EditDeviceWizard/steps/ApplicationInlineForm.d.ts.map +1 -1
  30. package/dist/src/components/Device/EditDeviceWizard/steps/ApplicationInlineForm.js +13 -9
  31. package/dist/src/components/Device/EditDeviceWizard/steps/ApplicationInlineForm.js.map +1 -1
  32. package/dist/src/components/Device/EditDeviceWizard/steps/ApplicationTemplates.d.ts +3 -1
  33. package/dist/src/components/Device/EditDeviceWizard/steps/ApplicationTemplates.d.ts.map +1 -1
  34. package/dist/src/components/Device/EditDeviceWizard/steps/ApplicationTemplates.js +20 -17
  35. package/dist/src/components/Device/EditDeviceWizard/steps/ApplicationTemplates.js.map +1 -1
  36. package/dist/src/components/Device/EditDeviceWizard/steps/ConfigInlineTemplateForm.d.ts +2 -1
  37. package/dist/src/components/Device/EditDeviceWizard/steps/ConfigInlineTemplateForm.d.ts.map +1 -1
  38. package/dist/src/components/Device/EditDeviceWizard/steps/ConfigInlineTemplateForm.js +18 -14
  39. package/dist/src/components/Device/EditDeviceWizard/steps/ConfigInlineTemplateForm.js.map +1 -1
  40. package/dist/src/components/Device/EditDeviceWizard/steps/ConfigWithRepositoryTemplateForm.d.ts +2 -1
  41. package/dist/src/components/Device/EditDeviceWizard/steps/ConfigWithRepositoryTemplateForm.d.ts.map +1 -1
  42. package/dist/src/components/Device/EditDeviceWizard/steps/ConfigWithRepositoryTemplateForm.js +21 -14
  43. package/dist/src/components/Device/EditDeviceWizard/steps/ConfigWithRepositoryTemplateForm.js.map +1 -1
  44. package/dist/src/components/Device/EditDeviceWizard/steps/ConfigurationTemplates.d.ts +3 -1
  45. package/dist/src/components/Device/EditDeviceWizard/steps/ConfigurationTemplates.d.ts.map +1 -1
  46. package/dist/src/components/Device/EditDeviceWizard/steps/ConfigurationTemplates.js +34 -20
  47. package/dist/src/components/Device/EditDeviceWizard/steps/ConfigurationTemplates.js.map +1 -1
  48. package/dist/src/components/Device/EditDeviceWizard/steps/DeviceTemplateStep.d.ts +2 -1
  49. package/dist/src/components/Device/EditDeviceWizard/steps/DeviceTemplateStep.d.ts.map +1 -1
  50. package/dist/src/components/Device/EditDeviceWizard/steps/DeviceTemplateStep.js +14 -15
  51. package/dist/src/components/Device/EditDeviceWizard/steps/DeviceTemplateStep.js.map +1 -1
  52. package/dist/src/components/Device/EditDeviceWizard/steps/DeviceUpdateStep.d.ts +3 -1
  53. package/dist/src/components/Device/EditDeviceWizard/steps/DeviceUpdateStep.d.ts.map +1 -1
  54. package/dist/src/components/Device/EditDeviceWizard/steps/DeviceUpdateStep.js +6 -36
  55. package/dist/src/components/Device/EditDeviceWizard/steps/DeviceUpdateStep.js.map +1 -1
  56. package/dist/src/components/Device/EditDeviceWizard/steps/GeneralInfoStep.js +1 -1
  57. package/dist/src/components/Device/EditDeviceWizard/steps/GeneralInfoStep.js.map +1 -1
  58. package/dist/src/components/Device/EditDeviceWizard/steps/ReviewDeviceStep.js +1 -1
  59. package/dist/src/components/Device/EditDeviceWizard/steps/ReviewDeviceStep.js.map +1 -1
  60. package/dist/src/components/Device/EditDeviceWizard/steps/ReviewUpdatePolicy.js +2 -2
  61. package/dist/src/components/Device/EditDeviceWizard/steps/ReviewUpdatePolicy.js.map +1 -1
  62. package/dist/src/components/Device/EditDeviceWizard/steps/SystemdUnitsForm.d.ts +4 -2
  63. package/dist/src/components/Device/EditDeviceWizard/steps/SystemdUnitsForm.d.ts.map +1 -1
  64. package/dist/src/components/Device/EditDeviceWizard/steps/SystemdUnitsForm.js +19 -1
  65. package/dist/src/components/Device/EditDeviceWizard/steps/SystemdUnitsForm.js.map +1 -1
  66. package/dist/src/components/Device/EditDeviceWizard/utils.d.ts +1 -14
  67. package/dist/src/components/Device/EditDeviceWizard/utils.d.ts.map +1 -1
  68. package/dist/src/components/Device/EditDeviceWizard/utils.js +3 -3
  69. package/dist/src/components/Device/EditDeviceWizard/utils.js.map +1 -1
  70. package/dist/src/components/Device/SystemdUnitsModal/SystemdUnitsModal.d.ts.map +1 -1
  71. package/dist/src/components/Device/SystemdUnitsModal/SystemdUnitsModal.js +28 -26
  72. package/dist/src/components/Device/SystemdUnitsModal/SystemdUnitsModal.js.map +1 -1
  73. package/dist/src/components/EnrollmentRequest/EnrollmentRequestDetails/EnrollmentRequestDetails.d.ts.map +1 -1
  74. package/dist/src/components/EnrollmentRequest/EnrollmentRequestDetails/EnrollmentRequestDetails.js +11 -16
  75. package/dist/src/components/EnrollmentRequest/EnrollmentRequestDetails/EnrollmentRequestDetails.js.map +1 -1
  76. package/dist/src/components/Events/EventItem.d.ts +7 -0
  77. package/dist/src/components/Events/EventItem.d.ts.map +1 -0
  78. package/dist/src/components/Events/EventItem.js +25 -0
  79. package/dist/src/components/Events/EventItem.js.map +1 -0
  80. package/dist/src/components/Events/EventsCard.css +5 -0
  81. package/dist/src/components/Events/EventsCard.d.ts +11 -0
  82. package/dist/src/components/Events/EventsCard.d.ts.map +1 -0
  83. package/dist/src/components/Events/EventsCard.js +81 -0
  84. package/dist/src/components/Events/EventsCard.js.map +1 -0
  85. package/dist/src/components/Events/useEvents.d.ts +21 -0
  86. package/dist/src/components/Events/useEvents.d.ts.map +1 -0
  87. package/dist/src/components/Events/useEvents.js +105 -0
  88. package/dist/src/components/Events/useEvents.js.map +1 -0
  89. package/dist/src/components/Fleet/CreateFleet/CreateFleetWizard.d.ts.map +1 -1
  90. package/dist/src/components/Fleet/CreateFleet/CreateFleetWizard.js +27 -9
  91. package/dist/src/components/Fleet/CreateFleet/CreateFleetWizard.js.map +1 -1
  92. package/dist/src/components/Fleet/CreateFleet/CreateFleetWizardFooter.d.ts +2 -1
  93. package/dist/src/components/Fleet/CreateFleet/CreateFleetWizardFooter.d.ts.map +1 -1
  94. package/dist/src/components/Fleet/CreateFleet/CreateFleetWizardFooter.js +13 -2
  95. package/dist/src/components/Fleet/CreateFleet/CreateFleetWizardFooter.js.map +1 -1
  96. package/dist/src/components/Fleet/CreateFleet/fleetSpecUtils.d.ts +3 -33
  97. package/dist/src/components/Fleet/CreateFleet/fleetSpecUtils.d.ts.map +1 -1
  98. package/dist/src/components/Fleet/CreateFleet/fleetSpecUtils.js +7 -21
  99. package/dist/src/components/Fleet/CreateFleet/fleetSpecUtils.js.map +1 -1
  100. package/dist/src/components/Fleet/CreateFleet/steps/DeviceLabelSelector.d.ts +4 -2
  101. package/dist/src/components/Fleet/CreateFleet/steps/DeviceLabelSelector.d.ts.map +1 -1
  102. package/dist/src/components/Fleet/CreateFleet/steps/DeviceLabelSelector.js +10 -1
  103. package/dist/src/components/Fleet/CreateFleet/steps/DeviceLabelSelector.js.map +1 -1
  104. package/dist/src/components/Fleet/CreateFleet/steps/GeneralInfoStep.d.ts +5 -3
  105. package/dist/src/components/Fleet/CreateFleet/steps/GeneralInfoStep.d.ts.map +1 -1
  106. package/dist/src/components/Fleet/CreateFleet/steps/GeneralInfoStep.js +4 -4
  107. package/dist/src/components/Fleet/CreateFleet/steps/GeneralInfoStep.js.map +1 -1
  108. package/dist/src/components/Fleet/CreateFleet/steps/ReviewStep.d.ts.map +1 -1
  109. package/dist/src/components/Fleet/CreateFleet/steps/ReviewStep.js +10 -9
  110. package/dist/src/components/Fleet/CreateFleet/steps/ReviewStep.js.map +1 -1
  111. package/dist/src/components/Fleet/CreateFleet/steps/UpdatePolicyStep.d.ts +3 -1
  112. package/dist/src/components/Fleet/CreateFleet/steps/UpdatePolicyStep.d.ts.map +1 -1
  113. package/dist/src/components/Fleet/CreateFleet/steps/UpdatePolicyStep.js +8 -86
  114. package/dist/src/components/Fleet/CreateFleet/steps/UpdatePolicyStep.js.map +1 -1
  115. package/dist/src/components/Fleet/CreateFleet/steps/UpdateStepDisruptionBudget.d.ts +3 -1
  116. package/dist/src/components/Fleet/CreateFleet/steps/UpdateStepDisruptionBudget.d.ts.map +1 -1
  117. package/dist/src/components/Fleet/CreateFleet/steps/UpdateStepDisruptionBudget.js +4 -4
  118. package/dist/src/components/Fleet/CreateFleet/steps/UpdateStepDisruptionBudget.js.map +1 -1
  119. package/dist/src/components/Fleet/CreateFleet/steps/UpdateStepRolloutPolicy.d.ts +3 -1
  120. package/dist/src/components/Fleet/CreateFleet/steps/UpdateStepRolloutPolicy.d.ts.map +1 -1
  121. package/dist/src/components/Fleet/CreateFleet/steps/UpdateStepRolloutPolicy.js +16 -13
  122. package/dist/src/components/Fleet/CreateFleet/steps/UpdateStepRolloutPolicy.js.map +1 -1
  123. package/dist/src/components/Fleet/CreateFleet/steps/UpdateStepUpdatePolicy.d.ts +3 -1
  124. package/dist/src/components/Fleet/CreateFleet/steps/UpdateStepUpdatePolicy.d.ts.map +1 -1
  125. package/dist/src/components/Fleet/CreateFleet/steps/UpdateStepUpdatePolicy.js +20 -20
  126. package/dist/src/components/Fleet/CreateFleet/steps/UpdateStepUpdatePolicy.js.map +1 -1
  127. package/dist/src/components/Fleet/CreateFleet/utils.d.ts +1 -1
  128. package/dist/src/components/Fleet/CreateFleet/utils.d.ts.map +1 -1
  129. package/dist/src/components/Fleet/CreateFleet/utils.js +37 -23
  130. package/dist/src/components/Fleet/CreateFleet/utils.js.map +1 -1
  131. package/dist/src/components/Fleet/DeleteFleetModal/DeleteFleetModal.d.ts.map +1 -1
  132. package/dist/src/components/Fleet/DeleteFleetModal/DeleteFleetModal.js +20 -16
  133. package/dist/src/components/Fleet/DeleteFleetModal/DeleteFleetModal.js.map +1 -1
  134. package/dist/src/components/Fleet/FleetDetails/FleetDetailsContent.d.ts.map +1 -1
  135. package/dist/src/components/Fleet/FleetDetails/FleetDetailsContent.js +8 -5
  136. package/dist/src/components/Fleet/FleetDetails/FleetDetailsContent.js.map +1 -1
  137. package/dist/src/components/Fleet/FleetDetails/{FleetDetails.d.ts → FleetDetailsPage.d.ts} +1 -1
  138. package/dist/src/components/Fleet/FleetDetails/FleetDetailsPage.d.ts.map +1 -0
  139. package/dist/src/components/Fleet/FleetDetails/{FleetDetails.js → FleetDetailsPage.js} +23 -17
  140. package/dist/src/components/Fleet/FleetDetails/FleetDetailsPage.js.map +1 -0
  141. package/dist/src/components/Fleet/FleetRow.d.ts.map +1 -1
  142. package/dist/src/components/Fleet/FleetRow.js +9 -12
  143. package/dist/src/components/Fleet/FleetRow.js.map +1 -1
  144. package/dist/src/components/Masthead/UserPreferencesModal.d.ts.map +1 -1
  145. package/dist/src/components/Masthead/UserPreferencesModal.js +14 -15
  146. package/dist/src/components/Masthead/UserPreferencesModal.js.map +1 -1
  147. package/dist/src/components/Masthead/UserPreferencesProvider.d.ts +8 -5
  148. package/dist/src/components/Masthead/UserPreferencesProvider.d.ts.map +1 -1
  149. package/dist/src/components/Masthead/UserPreferencesProvider.js +7 -5
  150. package/dist/src/components/Masthead/UserPreferencesProvider.js.map +1 -1
  151. package/dist/src/components/Repository/CreateRepository/CreateRepositoryForm.d.ts.map +1 -1
  152. package/dist/src/components/Repository/CreateRepository/CreateRepositoryForm.js +11 -7
  153. package/dist/src/components/Repository/CreateRepository/CreateRepositoryForm.js.map +1 -1
  154. package/dist/src/components/Repository/CreateRepository/utils.d.ts.map +1 -1
  155. package/dist/src/components/Repository/CreateRepository/utils.js +2 -3
  156. package/dist/src/components/Repository/CreateRepository/utils.js.map +1 -1
  157. package/dist/src/components/Repository/RepositoryDetails/DeleteRepositoryModal.d.ts.map +1 -1
  158. package/dist/src/components/Repository/RepositoryDetails/DeleteRepositoryModal.js +25 -24
  159. package/dist/src/components/Repository/RepositoryDetails/DeleteRepositoryModal.js.map +1 -1
  160. package/dist/src/components/Repository/RepositoryDetails/RepositoryDetails.d.ts.map +1 -1
  161. package/dist/src/components/Repository/RepositoryDetails/RepositoryDetails.js +22 -8
  162. package/dist/src/components/Repository/RepositoryDetails/RepositoryDetails.js.map +1 -1
  163. package/dist/src/components/ResourceSync/RepositoryResourceSyncList.d.ts.map +1 -1
  164. package/dist/src/components/ResourceSync/RepositoryResourceSyncList.js +18 -15
  165. package/dist/src/components/ResourceSync/RepositoryResourceSyncList.js.map +1 -1
  166. package/dist/src/components/common/CodeEditor/CodeEditorTheme.d.ts +5 -0
  167. package/dist/src/components/common/CodeEditor/CodeEditorTheme.d.ts.map +1 -0
  168. package/dist/src/components/common/CodeEditor/CodeEditorTheme.js +52 -0
  169. package/dist/src/components/common/CodeEditor/CodeEditorTheme.js.map +1 -0
  170. package/dist/src/components/common/CodeEditor/Shortcut.css +22 -0
  171. package/dist/src/components/common/CodeEditor/Shortcut.d.ts +20 -0
  172. package/dist/src/components/common/CodeEditor/Shortcut.d.ts.map +1 -0
  173. package/dist/src/components/common/CodeEditor/Shortcut.js +46 -0
  174. package/dist/src/components/common/CodeEditor/Shortcut.js.map +1 -0
  175. package/dist/src/components/common/CodeEditor/YamlEditor.css +12 -0
  176. package/dist/src/components/common/CodeEditor/YamlEditor.d.ts +16 -0
  177. package/dist/src/components/common/CodeEditor/YamlEditor.d.ts.map +1 -0
  178. package/dist/src/components/common/CodeEditor/YamlEditor.js +48 -0
  179. package/dist/src/components/common/CodeEditor/YamlEditor.js.map +1 -0
  180. package/dist/src/components/common/CodeEditor/YamlEditorBase.css +3 -0
  181. package/dist/src/components/common/CodeEditor/YamlEditorBase.d.ts +11 -0
  182. package/dist/src/components/common/CodeEditor/YamlEditorBase.d.ts.map +1 -0
  183. package/dist/src/components/common/CodeEditor/YamlEditorBase.js +75 -0
  184. package/dist/src/components/common/CodeEditor/YamlEditorBase.js.map +1 -0
  185. package/dist/src/components/common/CodeEditor/useShortcutPopover.d.ts +3 -0
  186. package/dist/src/components/common/CodeEditor/useShortcutPopover.d.ts.map +1 -0
  187. package/dist/src/components/common/CodeEditor/useShortcutPopover.js +26 -0
  188. package/dist/src/components/common/CodeEditor/useShortcutPopover.js.map +1 -0
  189. package/dist/src/components/common/LabelsView.d.ts +1 -3
  190. package/dist/src/components/common/LabelsView.d.ts.map +1 -1
  191. package/dist/src/components/common/LabelsView.js +2 -4
  192. package/dist/src/components/common/LabelsView.js.map +1 -1
  193. package/dist/src/components/common/LeaveFormConfirmation.d.ts.map +1 -1
  194. package/dist/src/components/common/LeaveFormConfirmation.js +8 -7
  195. package/dist/src/components/common/LeaveFormConfirmation.js.map +1 -1
  196. package/dist/src/components/common/TechPreviewBadge.d.ts.map +1 -1
  197. package/dist/src/components/common/TechPreviewBadge.js +3 -2
  198. package/dist/src/components/common/TechPreviewBadge.js.map +1 -1
  199. package/dist/src/components/form/FlightCtlActionGroup.d.ts +1 -1
  200. package/dist/src/components/form/FlightCtlActionGroup.d.ts.map +1 -1
  201. package/dist/src/components/form/FlightCtlActionGroup.js.map +1 -1
  202. package/dist/src/components/form/FormSelect.d.ts +4 -2
  203. package/dist/src/components/form/FormSelect.d.ts.map +1 -1
  204. package/dist/src/components/form/FormSelect.js +12 -1
  205. package/dist/src/components/form/FormSelect.js.map +1 -1
  206. package/dist/src/components/form/FormSelectTypeahead.d.ts +4 -3
  207. package/dist/src/components/form/FormSelectTypeahead.d.ts.map +1 -1
  208. package/dist/src/components/form/FormSelectTypeahead.js +18 -1
  209. package/dist/src/components/form/FormSelectTypeahead.js.map +1 -1
  210. package/dist/src/components/form/LabelsField.d.ts +4 -3
  211. package/dist/src/components/form/LabelsField.d.ts.map +1 -1
  212. package/dist/src/components/form/LabelsField.js +15 -5
  213. package/dist/src/components/form/LabelsField.js.map +1 -1
  214. package/dist/src/components/form/NameField.d.ts +2 -2
  215. package/dist/src/components/form/NameField.d.ts.map +1 -1
  216. package/dist/src/components/form/NameField.js +14 -4
  217. package/dist/src/components/form/NameField.js.map +1 -1
  218. package/dist/src/components/form/RichValidationTextField.d.ts +2 -2
  219. package/dist/src/components/form/RichValidationTextField.d.ts.map +1 -1
  220. package/dist/src/components/form/RichValidationTextField.js +13 -1
  221. package/dist/src/components/form/RichValidationTextField.js.map +1 -1
  222. package/dist/src/components/form/TextListField.d.ts +4 -2
  223. package/dist/src/components/form/TextListField.d.ts.map +1 -1
  224. package/dist/src/components/form/TextListField.js +13 -3
  225. package/dist/src/components/form/TextListField.js.map +1 -1
  226. package/dist/src/components/form/UploadField.d.ts +3 -2
  227. package/dist/src/components/form/UploadField.d.ts.map +1 -1
  228. package/dist/src/components/form/UploadField.js +10 -1
  229. package/dist/src/components/form/UploadField.js.map +1 -1
  230. package/dist/src/components/form/validations.js +1 -1
  231. package/dist/src/components/form/validations.js.map +1 -1
  232. package/dist/src/components/modals/ApproveDeviceModal/ApproveDeviceModal.d.ts.map +1 -1
  233. package/dist/src/components/modals/ApproveDeviceModal/ApproveDeviceModal.js +4 -1
  234. package/dist/src/components/modals/ApproveDeviceModal/ApproveDeviceModal.js.map +1 -1
  235. package/dist/src/components/modals/CreateRepositoryModal/CreateRepositoryModal.d.ts.map +1 -1
  236. package/dist/src/components/modals/CreateRepositoryModal/CreateRepositoryModal.js +5 -3
  237. package/dist/src/components/modals/CreateRepositoryModal/CreateRepositoryModal.js.map +1 -1
  238. package/dist/src/components/modals/DecommissionModal/DecommissionModal.d.ts.map +1 -1
  239. package/dist/src/components/modals/DecommissionModal/DecommissionModal.js +32 -29
  240. package/dist/src/components/modals/DecommissionModal/DecommissionModal.js.map +1 -1
  241. package/dist/src/components/modals/DeleteModal/DeleteModal.d.ts.map +1 -1
  242. package/dist/src/components/modals/DeleteModal/DeleteModal.js +18 -15
  243. package/dist/src/components/modals/DeleteModal/DeleteModal.js.map +1 -1
  244. package/dist/src/components/modals/massModals/MassApproveDeviceModal/MassApproveDeviceModal.d.ts.map +1 -1
  245. package/dist/src/components/modals/massModals/MassApproveDeviceModal/MassApproveDeviceModal.js +33 -30
  246. package/dist/src/components/modals/massModals/MassApproveDeviceModal/MassApproveDeviceModal.js.map +1 -1
  247. package/dist/src/components/modals/massModals/MassDecommissionDeviceModal/MassDecommissionDeviceModal.d.ts.map +1 -1
  248. package/dist/src/components/modals/massModals/MassDecommissionDeviceModal/MassDecommissionDeviceModal.js +27 -24
  249. package/dist/src/components/modals/massModals/MassDecommissionDeviceModal/MassDecommissionDeviceModal.js.map +1 -1
  250. package/dist/src/components/modals/massModals/MassDeleteDeviceModal/MassDeleteDeviceModal.d.ts.map +1 -1
  251. package/dist/src/components/modals/massModals/MassDeleteDeviceModal/MassDeleteDeviceModal.js +26 -23
  252. package/dist/src/components/modals/massModals/MassDeleteDeviceModal/MassDeleteDeviceModal.js.map +1 -1
  253. package/dist/src/components/modals/massModals/MassDeleteFleetModal/MassDeleteFleetModal.d.ts.map +1 -1
  254. package/dist/src/components/modals/massModals/MassDeleteFleetModal/MassDeleteFleetModal.js +30 -25
  255. package/dist/src/components/modals/massModals/MassDeleteFleetModal/MassDeleteFleetModal.js.map +1 -1
  256. package/dist/src/components/modals/massModals/MassDeleteRepositoryModal/MassDeleteRepositoryModal.d.ts.map +1 -1
  257. package/dist/src/components/modals/massModals/MassDeleteRepositoryModal/MassDeleteRepositoryModal.js +29 -26
  258. package/dist/src/components/modals/massModals/MassDeleteRepositoryModal/MassDeleteRepositoryModal.js.map +1 -1
  259. package/dist/src/components/modals/massModals/MassDeleteResourceSyncModal/MassDeleteResourceSyncModal.d.ts +1 -1
  260. package/dist/src/components/modals/massModals/MassDeleteResourceSyncModal/MassDeleteResourceSyncModal.d.ts.map +1 -1
  261. package/dist/src/components/modals/massModals/MassDeleteResourceSyncModal/MassDeleteResourceSyncModal.js +28 -25
  262. package/dist/src/components/modals/massModals/MassDeleteResourceSyncModal/MassDeleteResourceSyncModal.js.map +1 -1
  263. package/dist/src/constants.d.ts +2 -1
  264. package/dist/src/constants.d.ts.map +1 -1
  265. package/dist/src/constants.js +3 -1
  266. package/dist/src/constants.js.map +1 -1
  267. package/dist/src/hooks/useAppLinks.d.ts +5 -0
  268. package/dist/src/hooks/useAppLinks.d.ts.map +1 -0
  269. package/dist/src/hooks/useAppLinks.js +45 -0
  270. package/dist/src/hooks/useAppLinks.js.map +1 -0
  271. package/dist/src/{components/EnrollmentRequest/EnrollmentRequestDetails/useEnrollmentRequestSystemInfo.d.ts → hooks/useDeviceSpecSystemInfo.d.ts} +2 -2
  272. package/dist/src/hooks/useDeviceSpecSystemInfo.d.ts.map +1 -0
  273. package/dist/src/{components/EnrollmentRequest/EnrollmentRequestDetails/useEnrollmentRequestSystemInfo.js → hooks/useDeviceSpecSystemInfo.js} +18 -10
  274. package/dist/src/hooks/useDeviceSpecSystemInfo.js.map +1 -0
  275. package/dist/src/hooks/useFetchPeriodically.d.ts +2 -2
  276. package/dist/src/hooks/useFetchPeriodically.d.ts.map +1 -1
  277. package/dist/src/hooks/useFetchPeriodically.js +1 -1
  278. package/dist/src/hooks/useFetchPeriodically.js.map +1 -1
  279. package/dist/src/hooks/useThemePreferences.d.ts +6 -3
  280. package/dist/src/hooks/useThemePreferences.d.ts.map +1 -1
  281. package/dist/src/hooks/useThemePreferences.js +46 -23
  282. package/dist/src/hooks/useThemePreferences.js.map +1 -1
  283. package/dist/src/types/deviceSpec.d.ts +7 -1
  284. package/dist/src/types/deviceSpec.d.ts.map +1 -1
  285. package/dist/src/types/deviceSpec.js +16 -12
  286. package/dist/src/types/deviceSpec.js.map +1 -1
  287. package/dist/src/types/extraTypes.d.ts +3 -2
  288. package/dist/src/types/extraTypes.d.ts.map +1 -1
  289. package/dist/src/types/extraTypes.js.map +1 -1
  290. package/dist/src/utils/dates.d.ts +2 -1
  291. package/dist/src/utils/dates.d.ts.map +1 -1
  292. package/dist/src/utils/dates.js +20 -20
  293. package/dist/src/utils/dates.js.map +1 -1
  294. package/dist/src/utils/patch.d.ts.map +1 -1
  295. package/dist/src/utils/patch.js +2 -1
  296. package/dist/src/utils/patch.js.map +1 -1
  297. package/package.json +6 -2
  298. package/src/components/DetailsPage/DetailsPageActions.tsx +2 -1
  299. package/src/components/Device/AddDeviceModal/AddDeviceModal.tsx +27 -22
  300. package/src/components/Device/DeviceDetails/DeviceDetailsPage.tsx +10 -19
  301. package/src/components/Device/DeviceDetails/DeviceDetailsTab.tsx +65 -21
  302. package/src/components/Device/DevicesPage/DecommissionedDevicesTable.tsx +2 -2
  303. package/src/components/Device/DevicesPage/EnrolledDevicesTable.tsx +2 -2
  304. package/src/components/Device/EditDeviceWizard/EditDeviceWizard.tsx +6 -1
  305. package/src/components/Device/EditDeviceWizard/deviceSpecUtils.ts +28 -1
  306. package/src/components/Device/EditDeviceWizard/steps/ApplicationImageForm.tsx +19 -5
  307. package/src/components/Device/EditDeviceWizard/steps/ApplicationInlineForm.tsx +53 -23
  308. package/src/components/Device/EditDeviceWizard/steps/ApplicationTemplates.tsx +68 -53
  309. package/src/components/Device/EditDeviceWizard/steps/ConfigInlineTemplateForm.tsx +40 -25
  310. package/src/components/Device/EditDeviceWizard/steps/ConfigWithRepositoryTemplateForm.tsx +39 -5
  311. package/src/components/Device/EditDeviceWizard/steps/ConfigurationTemplates.tsx +81 -38
  312. package/src/components/Device/EditDeviceWizard/steps/DeviceTemplateStep.tsx +15 -19
  313. package/src/components/Device/EditDeviceWizard/steps/DeviceUpdateStep.tsx +7 -47
  314. package/src/components/Device/EditDeviceWizard/steps/GeneralInfoStep.tsx +1 -1
  315. package/src/components/Device/EditDeviceWizard/steps/ReviewDeviceStep.tsx +1 -1
  316. package/src/components/Device/EditDeviceWizard/steps/ReviewUpdatePolicy.tsx +2 -2
  317. package/src/components/Device/EditDeviceWizard/steps/SystemdUnitsForm.tsx +30 -2
  318. package/src/components/Device/EditDeviceWizard/utils.ts +6 -7
  319. package/src/components/Device/SystemdUnitsModal/SystemdUnitsModal.tsx +38 -35
  320. package/src/components/EnrollmentRequest/EnrollmentRequestDetails/EnrollmentRequestDetails.tsx +8 -19
  321. package/src/components/Events/EventItem.tsx +38 -0
  322. package/src/components/Events/EventsCard.css +5 -0
  323. package/src/components/Events/EventsCard.tsx +157 -0
  324. package/src/components/Events/useEvents.ts +136 -0
  325. package/src/components/Fleet/CreateFleet/CreateFleetWizard.tsx +29 -13
  326. package/src/components/Fleet/CreateFleet/CreateFleetWizardFooter.tsx +25 -10
  327. package/src/components/Fleet/CreateFleet/fleetSpecUtils.ts +9 -23
  328. package/src/components/Fleet/CreateFleet/steps/DeviceLabelSelector.tsx +12 -1
  329. package/src/components/Fleet/CreateFleet/steps/GeneralInfoStep.tsx +10 -5
  330. package/src/components/Fleet/CreateFleet/steps/ReviewStep.tsx +20 -17
  331. package/src/components/Fleet/CreateFleet/steps/UpdatePolicyStep.tsx +18 -122
  332. package/src/components/Fleet/CreateFleet/steps/UpdateStepDisruptionBudget.tsx +4 -1
  333. package/src/components/Fleet/CreateFleet/steps/UpdateStepRolloutPolicy.tsx +50 -31
  334. package/src/components/Fleet/CreateFleet/steps/UpdateStepUpdatePolicy.tsx +57 -12
  335. package/src/components/Fleet/CreateFleet/utils.ts +40 -22
  336. package/src/components/Fleet/DeleteFleetModal/DeleteFleetModal.tsx +28 -28
  337. package/src/components/Fleet/FleetDetails/FleetDetailsContent.tsx +10 -9
  338. package/src/components/Fleet/FleetDetails/{FleetDetails.tsx → FleetDetailsPage.tsx} +40 -25
  339. package/src/components/Fleet/FleetRow.tsx +10 -11
  340. package/src/components/Masthead/UserPreferencesModal.tsx +43 -56
  341. package/src/components/Masthead/UserPreferencesProvider.tsx +15 -10
  342. package/src/components/Repository/CreateRepository/CreateRepositoryForm.tsx +14 -15
  343. package/src/components/Repository/CreateRepository/utils.ts +2 -3
  344. package/src/components/Repository/RepositoryDetails/DeleteRepositoryModal.tsx +54 -55
  345. package/src/components/Repository/RepositoryDetails/RepositoryDetails.tsx +47 -14
  346. package/src/components/ResourceSync/RepositoryResourceSyncList.tsx +28 -25
  347. package/src/components/common/CodeEditor/CodeEditorTheme.ts +53 -0
  348. package/src/components/common/CodeEditor/Shortcut.css +22 -0
  349. package/src/components/common/CodeEditor/Shortcut.tsx +90 -0
  350. package/src/components/common/CodeEditor/YamlEditor.css +12 -0
  351. package/src/components/common/CodeEditor/YamlEditor.tsx +81 -0
  352. package/src/components/common/CodeEditor/YamlEditorBase.css +3 -0
  353. package/src/components/common/CodeEditor/YamlEditorBase.tsx +124 -0
  354. package/src/components/common/CodeEditor/useShortcutPopover.tsx +39 -0
  355. package/src/components/common/LabelsView.tsx +2 -11
  356. package/src/components/common/LeaveFormConfirmation.tsx +14 -18
  357. package/src/components/common/TechPreviewBadge.tsx +3 -1
  358. package/src/components/form/FlightCtlActionGroup.tsx +1 -1
  359. package/src/components/form/FormSelect.tsx +14 -3
  360. package/src/components/form/FormSelectTypeahead.tsx +24 -3
  361. package/src/components/form/LabelsField.tsx +20 -20
  362. package/src/components/form/NameField.tsx +18 -4
  363. package/src/components/form/RichValidationTextField.tsx +20 -1
  364. package/src/components/form/TextListField.tsx +19 -3
  365. package/src/components/form/UploadField.tsx +16 -2
  366. package/src/components/form/validations.ts +1 -1
  367. package/src/components/modals/ApproveDeviceModal/ApproveDeviceModal.tsx +12 -7
  368. package/src/components/modals/CreateRepositoryModal/CreateRepositoryModal.tsx +6 -3
  369. package/src/components/modals/DecommissionModal/DecommissionModal.tsx +60 -56
  370. package/src/components/modals/DeleteModal/DeleteModal.tsx +25 -27
  371. package/src/components/modals/massModals/MassApproveDeviceModal/MassApproveDeviceModal.tsx +81 -92
  372. package/src/components/modals/massModals/MassDecommissionDeviceModal/MassDecommissionDeviceModal.tsx +64 -67
  373. package/src/components/modals/massModals/MassDeleteDeviceModal/MassDeleteDeviceModal.tsx +60 -62
  374. package/src/components/modals/massModals/MassDeleteFleetModal/MassDeleteFleetModal.tsx +80 -87
  375. package/src/components/modals/massModals/MassDeleteRepositoryModal/MassDeleteRepositoryModal.tsx +70 -73
  376. package/src/components/modals/massModals/MassDeleteResourceSyncModal/MassDeleteResourceSyncModal.tsx +62 -63
  377. package/src/constants.ts +2 -1
  378. package/src/hooks/useAppLinks.ts +49 -0
  379. package/src/{components/EnrollmentRequest/EnrollmentRequestDetails/useEnrollmentRequestSystemInfo.tsx → hooks/useDeviceSpecSystemInfo.tsx} +15 -7
  380. package/src/hooks/useFetchPeriodically.ts +3 -3
  381. package/src/hooks/useThemePreferences.ts +48 -21
  382. package/src/types/deviceSpec.ts +25 -12
  383. package/src/types/extraTypes.ts +7 -4
  384. package/src/utils/dates.ts +23 -24
  385. package/src/utils/patch.ts +3 -1
  386. package/dist/src/components/Device/DeviceDetails/DeviceStatusDebugModal.css +0 -3
  387. package/dist/src/components/Device/DeviceDetails/DeviceStatusDebugModal.d.ts +0 -9
  388. package/dist/src/components/Device/DeviceDetails/DeviceStatusDebugModal.d.ts.map +0 -1
  389. package/dist/src/components/Device/DeviceDetails/DeviceStatusDebugModal.js +0 -34
  390. package/dist/src/components/Device/DeviceDetails/DeviceStatusDebugModal.js.map +0 -1
  391. package/dist/src/components/EnrollmentRequest/EnrollmentRequestDetails/useEnrollmentRequestSystemInfo.d.ts.map +0 -1
  392. package/dist/src/components/EnrollmentRequest/EnrollmentRequestDetails/useEnrollmentRequestSystemInfo.js.map +0 -1
  393. package/dist/src/components/Fleet/CreateFleet/steps/UpdateConfirmChangesModal.d.ts +0 -9
  394. package/dist/src/components/Fleet/CreateFleet/steps/UpdateConfirmChangesModal.d.ts.map +0 -1
  395. package/dist/src/components/Fleet/CreateFleet/steps/UpdateConfirmChangesModal.js +0 -61
  396. package/dist/src/components/Fleet/CreateFleet/steps/UpdateConfirmChangesModal.js.map +0 -1
  397. package/dist/src/components/Fleet/FleetDetails/FleetDetails.d.ts.map +0 -1
  398. package/dist/src/components/Fleet/FleetDetails/FleetDetails.js.map +0 -1
  399. package/dist/src/components/common/LabelsView.css +0 -9
  400. package/dist/src/links.d.ts +0 -7
  401. package/dist/src/links.d.ts.map +0 -1
  402. package/dist/src/links.js +0 -14
  403. package/dist/src/links.js.map +0 -1
  404. package/src/components/Device/DeviceDetails/DeviceStatusDebugModal.css +0 -3
  405. package/src/components/Device/DeviceDetails/DeviceStatusDebugModal.tsx +0 -60
  406. package/src/components/Fleet/CreateFleet/steps/UpdateConfirmChangesModal.tsx +0 -96
  407. package/src/components/common/LabelsView.css +0 -9
  408. package/src/links.ts +0 -16
@@ -0,0 +1,49 @@
1
+ import { FlightCtlApp, useAppContext } from './useAppContext';
2
+
3
+ // Links to other flightctl upstream resources
4
+ export const DEMO_REPOSITORY_URL = 'https://github.com/flightctl/flightctl-demos';
5
+
6
+ const ACM_VERSION = '2.13';
7
+ const AAP_VERSION = '2.5';
8
+
9
+ const upstreamDocsBase = 'https://github.com/flightctl/flightctl/blob/main/docs';
10
+ const acmDownstreamDocsBase = `https://docs.redhat.com/en/documentation/red_hat_advanced_cluster_management_for_kubernetes/${ACM_VERSION}/html-single/edge_manager/index`;
11
+ const aapDownstreamDocsBase = `https://docs.redhat.com/en/documentation/red_hat_ansible_automation_platform/${AAP_VERSION}/html/managing_device_fleets_with_the_red_hat_edge_manager`;
12
+
13
+ const links = {
14
+ fc: {
15
+ createApp: `${upstreamDocsBase}/user/managing-devices.md#creating-applications`,
16
+ useTemplateVars: `${upstreamDocsBase}/user/managing-fleets.md#defining-device-templates`,
17
+ addNewDevice: `${upstreamDocsBase}/user/getting-started.md#building-a-bootable-container-image-including-the-flight-control-agent`,
18
+ createAcmRepo: `${upstreamDocsBase}/user/registering-microshift-devices-acm.md#creating-the-acm-registration-repository`,
19
+ },
20
+ acm: {
21
+ createApp: `${acmDownstreamDocsBase}#build-app-packages`,
22
+ useTemplateVars: `${acmDownstreamDocsBase}#device-templates`,
23
+ addNewDevice: `${acmDownstreamDocsBase}#edge-mgr-build`,
24
+ createAcmRepo: `${acmDownstreamDocsBase}#device-config-git-cli`,
25
+ },
26
+ aap: {
27
+ createApp: `${aapDownstreamDocsBase}/edge-manager-manage-apps#edge-manager-build-app-packages`,
28
+ useTemplateVars: `${aapDownstreamDocsBase}/assembly-edge-manager-device-fleets#edge-manager-device-templates`,
29
+ addNewDevice: `${aapDownstreamDocsBase}/assembly-edge-manager-images#edge-manager-build-bootc`,
30
+ createAcmRepo: '',
31
+ },
32
+ };
33
+
34
+ type AppLink = 'createApp' | 'useTemplateVars' | 'addNewDevice' | 'createAcmRepo';
35
+
36
+ const getLinkSource = (appType: FlightCtlApp, isRHEM?: boolean) => {
37
+ // Default doc links are AAP's and apply when using RHEM branding
38
+ if (isRHEM || appType === FlightCtlApp.AAP) {
39
+ return links.aap;
40
+ }
41
+ return appType === FlightCtlApp.STANDALONE ? links.fc : links.acm;
42
+ };
43
+
44
+ export const useAppLinks = (link: AppLink) => {
45
+ const { appType, settings } = useAppContext();
46
+
47
+ const links = getLinkSource(appType, settings.isRHEM);
48
+ return links[link];
49
+ };
@@ -28,11 +28,12 @@ const emptySystemInfo = {
28
28
  const excludedKnownProps = [
29
29
  'distroVersion', // It's combined with "distroName"
30
30
  'customInfo', // Custom properies are evaluated separately from the predefined, known properties
31
- 'architecture', // Rendered separately by EnrollmentRequestDetails
32
- 'operatingSystem', // Rendered separately by EnrollmentRequestDetails
31
+ 'attestation', // In Phase1 this includes only the raw data, without a report of success or failure.
33
32
  ];
34
33
 
35
34
  const getInfoDataKnownKeys = (t: TFunction) => ({
35
+ architecture: t('Architecture'),
36
+ operatingSystem: t('Operating system'),
36
37
  agentVersion: t('Agent version'),
37
38
  distroName: t('Distro'),
38
39
  hostname: t('Hostname'),
@@ -44,9 +45,10 @@ const getInfoDataKnownKeys = (t: TFunction) => ({
44
45
  productName: t('Product name'),
45
46
  productSerial: t('Product serial'),
46
47
  productUuid: t('Product UUID'),
48
+ tpmVendorInfo: t('TPM vendor info'),
47
49
  });
48
50
 
49
- export const useEnrollmentRequestSystemInfo = (
51
+ export const useDeviceSpecSystemInfo = (
50
52
  systemInfo: FixedDeviceSystemInfo | undefined,
51
53
  t: TFunction,
52
54
  ): {
@@ -64,11 +66,17 @@ export const useEnrollmentRequestSystemInfo = (
64
66
  return !excludedKnownProps.includes(infoKey) && systemInfo[infoKey];
65
67
  })
66
68
  .map(([infoKey, infoTitle]) => {
67
- let infoDataValue = systemInfo[infoKey];
69
+ let infoDataValue: string;
68
70
 
69
- if (infoKey === 'distroName') {
70
- const version = 'distroVersion' in systemInfo ? ` ${systemInfo['distroVersion']}` : '';
71
- infoDataValue = `${infoDataValue}${version}`;
71
+ switch (infoKey) {
72
+ case 'distroName':
73
+ infoDataValue =
74
+ 'distroVersion' in systemInfo
75
+ ? `${systemInfo.distroName} ${systemInfo.distroVersion}`
76
+ : systemInfo.distroName;
77
+ break;
78
+ default:
79
+ infoDataValue = systemInfo[infoKey];
72
80
  }
73
81
 
74
82
  return {
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { FlightControlQuery } from '../types/extraTypes';
2
+ import { ApiQuery } from '../types/extraTypes';
3
3
  import { getQueryStringHash, getRequestQueryString } from '../utils/api';
4
4
 
5
5
  import { useFetch } from './useFetch';
@@ -7,7 +7,7 @@ import { useFetch } from './useFetch';
7
7
  const TIMEOUT = 10000;
8
8
 
9
9
  export const useFetchPeriodically = <R>(
10
- query: FlightControlQuery,
10
+ query: ApiQuery,
11
11
  onFetchComplete?: (data: R) => void,
12
12
  ): [R | undefined, boolean, unknown, VoidFunction, boolean] => {
13
13
  const [isLoading, setIsLoading] = React.useState(true);
@@ -67,7 +67,7 @@ export const useFetchPeriodically = <R>(
67
67
  setData(undefined);
68
68
  }
69
69
  prevResolvedQueryHash.current = queryStringHash;
70
- await new Promise((resolve) => setTimeout(resolve, TIMEOUT));
70
+ await new Promise((resolve) => setTimeout(resolve, query.timeout || TIMEOUT));
71
71
  }
72
72
  };
73
73
 
@@ -2,18 +2,12 @@ import * as React from 'react';
2
2
  import { useUserPreferences } from './useUserPreferences';
3
3
 
4
4
  export const THEME_LOCAL_STORAGE_KEY = 'flightctl/theme';
5
+ export const OCP_CONSOLE_THEME_LOCAL_STORAGE_KEY = 'bridge/theme';
6
+
5
7
  const THEME_DARK_CLASS = 'pf-v5-theme-dark';
6
8
 
7
9
  export type Theme = 'dark' | 'light' | 'system';
8
-
9
- export const updateThemeClass = (htmlTagElement: HTMLElement, theme: string | null) => {
10
- const systemTheme: Theme = window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light';
11
- if (theme === 'dark' || (!theme && systemTheme === 'dark')) {
12
- htmlTagElement.classList.add(THEME_DARK_CLASS);
13
- } else {
14
- htmlTagElement.classList.remove(THEME_DARK_CLASS);
15
- }
16
- };
10
+ export type ResolvedTheme = Exclude<Theme, 'system'>;
17
11
 
18
12
  const getTheme = (storageTheme: string | null): Theme => {
19
13
  switch (storageTheme) {
@@ -29,9 +23,26 @@ const getTheme = (storageTheme: string | null): Theme => {
29
23
  }
30
24
  };
31
25
 
26
+ const getDarkThemeMq = () => window.matchMedia('(prefers-color-scheme: dark)');
27
+
28
+ const getResolvedTheme = (darkThemeMq: MediaQueryList, theme: string | null): ResolvedTheme => {
29
+ const isDarkPreferred = darkThemeMq.matches;
30
+ return theme === 'dark' || (isDarkPreferred && getTheme(theme) === 'system') ? 'dark' : 'light';
31
+ };
32
+
33
+ export const updateThemeClass = (htmlTagElement: HTMLElement, resolvedTheme: ResolvedTheme) => {
34
+ if (resolvedTheme === 'dark') {
35
+ htmlTagElement.classList.add(THEME_DARK_CLASS);
36
+ } else {
37
+ htmlTagElement.classList.remove(THEME_DARK_CLASS);
38
+ }
39
+ };
40
+
32
41
  export const useThemePreferences = () => {
33
42
  const htmlTagElement = document.documentElement;
34
- const [value, setValue] = useUserPreferences(THEME_LOCAL_STORAGE_KEY);
43
+ const [userTheme, setUserTheme] = useUserPreferences(THEME_LOCAL_STORAGE_KEY);
44
+ const [consoleTheme] = useUserPreferences(OCP_CONSOLE_THEME_LOCAL_STORAGE_KEY);
45
+ const [resolvedTheme, setResolvedTheme] = React.useState<ResolvedTheme>('light');
35
46
 
36
47
  React.useEffect(() => {
37
48
  const mqListener = (e: MediaQueryListEvent) => {
@@ -41,24 +52,40 @@ export const useThemePreferences = () => {
41
52
  htmlTagElement.classList.remove(THEME_DARK_CLASS);
42
53
  }
43
54
  };
44
- const darkThemeMq = window.matchMedia('(prefers-color-scheme: dark)');
45
- if (!value) {
46
- darkThemeMq.addEventListener('change', mqListener);
55
+ const darkThemeMq = getDarkThemeMq();
56
+ let actualTheme: ResolvedTheme;
57
+ if (consoleTheme) {
58
+ actualTheme = getResolvedTheme(darkThemeMq, consoleTheme);
59
+ } else {
60
+ actualTheme = getResolvedTheme(darkThemeMq, userTheme);
61
+ updateThemeClass(htmlTagElement, actualTheme);
62
+ if (!userTheme) {
63
+ darkThemeMq.addEventListener('change', mqListener);
64
+ }
47
65
  }
48
- updateThemeClass(htmlTagElement, value);
49
- return () => darkThemeMq.removeEventListener('change', mqListener);
50
- }, [htmlTagElement, value]);
66
+ setResolvedTheme(actualTheme);
67
+
68
+ return () => {
69
+ if (!consoleTheme && !userTheme) {
70
+ darkThemeMq.removeEventListener('change', mqListener);
71
+ }
72
+ };
73
+ }, [htmlTagElement, userTheme, consoleTheme]);
51
74
 
52
75
  const setThemeState = React.useCallback(
53
76
  (theme: Theme) => {
54
- setValue(theme);
55
- updateThemeClass(htmlTagElement, theme);
77
+ const darkTheme = getDarkThemeMq();
78
+ const actualTheme = getResolvedTheme(darkTheme, theme);
79
+ updateThemeClass(htmlTagElement, actualTheme);
80
+ setUserTheme(theme);
81
+ setResolvedTheme(actualTheme);
56
82
  },
57
- [htmlTagElement, setValue],
83
+ [htmlTagElement, setUserTheme],
58
84
  );
59
85
 
60
86
  return {
61
- theme: getTheme(value),
62
- setTheme: setThemeState,
87
+ userTheme: getTheme(userTheme),
88
+ setUserTheme: setThemeState,
89
+ resolvedTheme,
63
90
  };
64
91
  };
@@ -4,6 +4,7 @@ import {
4
4
  GitConfigProviderSpec,
5
5
  HttpConfigProviderSpec,
6
6
  ImageApplicationProviderSpec,
7
+ ImagePullPolicy,
7
8
  InlineApplicationProviderSpec,
8
9
  InlineConfigProviderSpec,
9
10
  KubernetesSecretProviderSpec,
@@ -48,6 +49,11 @@ type AppBase = {
48
49
  // appType: AppType - commented out for now, since it only accepts one value ("compose")
49
50
  name?: string;
50
51
  variables: { name: string; value: string }[];
52
+ volumes?: {
53
+ name: string;
54
+ reference: string;
55
+ pullPolicy?: ImagePullPolicy;
56
+ }[];
51
57
  };
52
58
 
53
59
  export type InlineAppForm = AppBase & {
@@ -96,25 +102,31 @@ export const getAppIdentifier = (app: AppForm) => {
96
102
  return app.name;
97
103
  };
98
104
 
105
+ const removeSlashes = (url: string | undefined) => (url || '').replace(/^\/+|\/+$/g, '');
106
+ const getFinalRepoUrl = (baseUrl: string, relativePath: string) => {
107
+ if (relativePath && !hasTemplateVariables(relativePath)) {
108
+ return `${baseUrl}/${relativePath}`;
109
+ }
110
+ return baseUrl;
111
+ };
112
+
99
113
  export const getConfigFullRepoUrl = (config: RepoConfig, repositoryUrl: string) => {
100
- let relativePath: string = '';
114
+ const baseUrl = removeSlashes(repositoryUrl).replace(/\.git\/?$/, '');
101
115
  if (isHttpProviderSpec(config)) {
102
- relativePath = (config.httpRef.suffix || '').replace(/^\//g, ''); // remove the leading slash
103
- } else if (isGitProviderSpec(config) && /github|gitlab/.test(repositoryUrl)) {
104
- const configPath = config.gitRef.path.replace(/^\//g, ''); // remove the leading slash
105
- const configParts = configPath.split('/');
106
- const lastPart = configParts[configParts.length - 1];
116
+ return getFinalRepoUrl(baseUrl, removeSlashes(config.httpRef.suffix));
117
+ }
118
+ if (isGitProviderSpec(config) && /github|gitlab/.test(repositoryUrl)) {
119
+ const configPath = removeSlashes(config.gitRef.path);
120
+ const pathSegments = configPath.split('/');
121
+ const lastSegment = pathSegments[pathSegments.length - 1];
107
122
 
108
123
  // Extension-less files cannot be identified as such. GitHub and Gitlab both redirect to the correct URL to show the file contents
109
- const fileOrDir = lastPart.includes('.') ? 'blob' : 'tree';
110
- relativePath = `${fileOrDir}/${config.gitRef.targetRevision}/${configPath}`;
124
+ const fileOrDir = lastSegment.includes('.') ? 'blob' : 'tree';
125
+ return getFinalRepoUrl(baseUrl, `${fileOrDir}/${config.gitRef.targetRevision}/${configPath}`);
111
126
  }
112
127
 
113
- if (relativePath && !hasTemplateVariables(relativePath)) {
114
- return `${repositoryUrl}/${relativePath}`;
115
- }
116
128
  // We return just the base repository URL as a fallback
117
- return repositoryUrl;
129
+ return baseUrl;
118
130
  };
119
131
 
120
132
  export const getRepoName = (config: RepoConfig) =>
@@ -171,6 +183,7 @@ export type DeviceSpecConfigFormValues = {
171
183
  systemdUnits: SystemdUnitFormValue[];
172
184
  updatePolicy: UpdatePolicyForm;
173
185
  registerMicroShift: boolean;
186
+ useBasicUpdateConfig: boolean;
174
187
  };
175
188
 
176
189
  export type EditDeviceFormValues = DeviceSpecConfigFormValues & {
@@ -1,6 +1,7 @@
1
1
  import {
2
2
  AppType,
3
3
  ApplicationEnvVars,
4
+ ApplicationVolumeProviderSpec,
4
5
  ConditionType,
5
6
  Device,
6
7
  EnrollmentRequest,
@@ -35,6 +36,7 @@ export interface FlightCtlLabel {
35
36
 
36
37
  export interface ApiQuery {
37
38
  endpoint: string;
39
+ timeout?: number;
38
40
  }
39
41
 
40
42
  export interface MetricsQuery {
@@ -66,10 +68,11 @@ export const isFleet = (resource: ResourceSync | Fleet): resource is Fleet => re
66
68
  export type InlineApplicationFileFixed = FileContent & RelativePath;
67
69
 
68
70
  // "FixedApplicationProviderSpec" will need to be manually adjusted whenever the API definition changes
69
- export type ApplicationProviderSpecFixed = ApplicationEnvVars & {
70
- name?: string;
71
- appType?: AppType;
72
- } & (ImageApplicationProviderSpec | { inline: InlineApplicationFileFixed[] });
71
+ export type ApplicationProviderSpecFixed = ApplicationEnvVars &
72
+ ApplicationVolumeProviderSpec & {
73
+ name?: string;
74
+ appType?: AppType;
75
+ } & (ImageApplicationProviderSpec | { inline: InlineApplicationFileFixed[] });
73
76
 
74
77
  type CliArtifact = {
75
78
  os: string;
@@ -1,37 +1,28 @@
1
1
  import { TFunction } from 'i18next';
2
2
 
3
- type ArgumentTypes = Parameters<typeof Intl.DateTimeFormat>;
4
-
5
3
  const EMPTY_DATE = '0001-01-01T00:00:00Z';
6
-
7
- // TODO use a date library and display dates according to user locale
8
- const getDateDisplay = (timestamp?: string, withTime: boolean = false) => {
4
+ const defaultLang = 'en-US';
5
+
6
+ const dateTimeFormatter = () =>
7
+ new Intl.DateTimeFormat(defaultLang, {
8
+ month: 'short',
9
+ day: 'numeric',
10
+ hour: 'numeric',
11
+ minute: 'numeric',
12
+ year: 'numeric',
13
+ });
14
+
15
+ const getDateDisplay = (timestamp?: string) => {
9
16
  if (!timestamp) {
10
17
  return 'N/A';
11
18
  }
12
19
 
13
- let options: ArgumentTypes[1];
14
- let timeStr = '';
15
-
16
- if (withTime) {
17
- options = { month: 'long', day: 'numeric' };
18
- timeStr = ` ${timestamp.slice(11, 16)}`;
19
- } else {
20
- options = { year: 'numeric', month: 'long', day: 'numeric' };
21
- }
22
-
23
- const date = new Date(timestamp);
24
- return `${new Intl.DateTimeFormat('en-GB', options).format(date)}${timeStr}`;
20
+ return dateTimeFormatter().format(new Date(timestamp));
25
21
  };
26
22
 
27
23
  // https://stackoverflow.com/questions/3177836/how-to-format-time-since-xxx-e-g-4-minutes-ago-similar-to-stack-exchange-site
28
- const timeSinceText = (t: TFunction, timestampStr?: string) => {
29
- if (!timestampStr || timestampStr === EMPTY_DATE) {
30
- return 'N/A';
31
- }
32
-
33
- const timestamp = new Date(timestampStr).getTime();
34
- const seconds = Math.floor((Date.now() - timestamp) / 1000);
24
+ export const timeSinceEpochText = (t: TFunction, epochOffset: number) => {
25
+ const seconds = Math.floor((Date.now() - epochOffset) / 1000);
35
26
 
36
27
  let interval = seconds / 31536000;
37
28
 
@@ -57,4 +48,12 @@ const timeSinceText = (t: TFunction, timestampStr?: string) => {
57
48
  return t('< 1 minute ago');
58
49
  };
59
50
 
51
+ const timeSinceText = (t: TFunction, timestampStr?: string) => {
52
+ if (!timestampStr || timestampStr === EMPTY_DATE) {
53
+ return 'N/A';
54
+ }
55
+
56
+ return timeSinceEpochText(t, new Date(timestampStr).getTime());
57
+ };
58
+
60
59
  export { getDateDisplay, timeSinceText };
@@ -261,7 +261,9 @@ export const getRolloutPolicyPatches = (
261
261
  const currentDisruption = currentPolicy?.disruptionBudget;
262
262
 
263
263
  const hadAdvancedSettings = currentBatches.length > 0 || !!currentDisruption;
264
- const wantsAdvancedSettings = fleetValues.rolloutPolicy.isAdvanced || fleetValues.disruptionBudget.isAdvanced;
264
+ const wantsAdvancedSettings =
265
+ !fleetValues.useBasicUpdateConfig &&
266
+ (fleetValues.rolloutPolicy.isAdvanced || fleetValues.disruptionBudget.isAdvanced);
265
267
  const updatedPolicy = fleetValues.rolloutPolicy;
266
268
 
267
269
  if (hadAdvancedSettings !== wantsAdvancedSettings) {
@@ -1,3 +0,0 @@
1
- .fctl-device-status-debug__actions {
2
- text-align: right;
3
- }
@@ -1,9 +0,0 @@
1
- import * as React from 'react';
2
- import { DeviceStatus } from '@flightctl/types';
3
- import './DeviceStatusDebugModal.css';
4
- declare const DeviceStatusDebugModal: ({ status, onClose }: {
5
- status: DeviceStatus;
6
- onClose: VoidFunction;
7
- }) => React.JSX.Element;
8
- export default DeviceStatusDebugModal;
9
- //# sourceMappingURL=DeviceStatusDebugModal.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DeviceStatusDebugModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/Device/DeviceDetails/DeviceStatusDebugModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAGhD,OAAO,8BAA8B,CAAC;AAEtC,QAAA,MAAM,sBAAsB;YAAmC,YAAY;aAAW,YAAY;uBA+CjG,CAAC;AAEF,eAAe,sBAAsB,CAAC"}
@@ -1,34 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const React = tslib_1.__importStar(require("react"));
5
- const react_core_1 = require("@patternfly/react-core");
6
- const copy_icon_1 = require("@patternfly/react-icons/dist/js/icons/copy-icon");
7
- const redo_icon_1 = require("@patternfly/react-icons/dist/js/icons/redo-icon");
8
- const useTranslation_1 = require("../../../hooks/useTranslation");
9
- require("./DeviceStatusDebugModal.css");
10
- const DeviceStatusDebugModal = ({ status, onClose }) => {
11
- const { t } = (0, useTranslation_1.useTranslation)();
12
- const [refreshVersion, setRefreshVersion] = React.useState(status.lastSeen);
13
- const statusJson = React.useMemo(() => {
14
- return JSON.stringify({ deviceStatus: status }, null, 3);
15
- // We only update the JSON when the "Refresh status" button is clicked
16
- // eslint-disable-next-line react-hooks/exhaustive-deps
17
- }, [refreshVersion]);
18
- const onCopy = () => {
19
- void navigator.clipboard.writeText(statusJson);
20
- };
21
- return (React.createElement(react_core_1.Modal, { variant: "medium", isOpen: true, title: t('Device status debug information'), showClose: true, disableFocusTrap: true, onClose: onClose },
22
- React.createElement(react_core_1.Stack, { hasGutter: true },
23
- React.createElement(react_core_1.StackItem, { className: "fctl-device-status-debug__actions" },
24
- React.createElement(react_core_1.Button, { variant: "primary", icon: React.createElement(copy_icon_1.CopyIcon, null), onClick: onCopy }, t('Copy debug info')),
25
- ' ',
26
- React.createElement(react_core_1.Button, { variant: "link", icon: React.createElement(redo_icon_1.RedoIcon, null), isDisabled: status.lastSeen === refreshVersion, onClick: () => {
27
- setRefreshVersion(status.lastSeen);
28
- } }, t('Load updated status'))),
29
- React.createElement(react_core_1.StackItem, null,
30
- React.createElement(react_core_1.CodeBlock, null,
31
- React.createElement(react_core_1.CodeBlockCode, null, statusJson))))));
32
- };
33
- exports.default = DeviceStatusDebugModal;
34
- //# sourceMappingURL=DeviceStatusDebugModal.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DeviceStatusDebugModal.js","sourceRoot":"","sources":["../../../../../src/components/Device/DeviceDetails/DeviceStatusDebugModal.tsx"],"names":[],"mappings":";;;AAAA,qDAA+B;AA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AE,GAAG,EAAE;wBACZ,iBAAiB,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;oBACrC,CAAC,IAEA,CAAC,CAAC,qBAAqB,CAAC,CAClB,CACC;YACZ,oBAAC,sBAAS;gBACR,oBAAC,sBAAS;oBACR,oBAAC,0BAAa,QAAE,UAAU,CAAiB,CACjC,CACF,CACN,CACF,CACT,CAAC;AACJ,CAAC,CAAC;AAEF,kBAAe,sBAAsB,CAAC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"useEnrollmentRequestSystemInfo.d.ts","sourceRoot":"","sources":["../../../../../src/components/EnrollmentRequest/EnrollmentRequestDetails/useEnrollmentRequestSystemInfo.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAE1C,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAGtE,MAAM,MAAM,qBAAqB,GAAG,gBAAgB,GAAG;IACrD,UAAU,CAAC,EAAE,gBAAgB,CAAC;CAC/B,CAAC;AAEF,KAAK,eAAe,GAAG;IACrB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAmCF,eAAO,MAAM,8BAA8B,eAC7B,qBAAqB,GAAG,SAAS,KAC1C,SAAS,KACX;IACD,QAAQ,EAAE,eAAe,EAAE,CAAC;IAC5B,UAAU,EAAE,eAAe,EAAE,CAAC;CA6D/B,CAAC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"useEnrollmentRequestSystemInfo.js","sourceRoot":"","sources":["../../../../../src/components/EnrollmentRequest/EnrollmentRequestDetails/useEnrollmentRequestSystemInfo.tsx"],"names":[],"mappings":";;;;AAAA,0DAA0B;AAe1B,yFAAyF;AACzF,iFAAiF;AACjF,MAAM,eAAe,GAAG,CAAC,KAAa,EAAE,EAAE;IACxC,MAAM,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,iBAAiB,EAAE,OAAO,CAAC,C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,UAAU,GAAG,UAAU,CAAC,UAAU,IAAI,EAAE,CAAC;QAC/C,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,OAAO,CAAC,CAAC,aAAa,EAAE,EAAE;YAChD,MAAM,KAAK,GAAG,UAAU,CAAC,aAAa,CAAC,CAAC;YACxC,IAAI,KAAK,EAAE,CAAC;gBACV,cAAc,CAAC,IAAI,CAAC;oBAClB,KAAK,EAAE,eAAe,CAAC,aAAa,CAAC;oBACrC,KAAK;iBACN,CAAC,CAAC;YACL,CAAC;QACH,CAAC,CAAC,CAAC;IACL,CAAC;IAAC,OAAO,CAAC,EAAE,CAAC;QACX,sCAAsC;QACtC,OAAO,CAAC,IAAI,CAAC,8BAA8B,EAAE,UAAU,CAAC,UAAU,CAAC,CAAC;IACtE,CAAC;IAED,OAAO;QACL,QAAQ,EAAE,YAAY;QACtB,UAAU,EAAE,cAAc;KAC3B,CAAC;AACJ,CAAC,CAAC;AAlEW,QAAA,8BAA8B,kCAkEzC"}
@@ -1,9 +0,0 @@
1
- import * as React from 'react';
2
- export type StepSetting = 'all-settings' | 'rollout-policies' | 'update-policies' | 'disruption-budget';
3
- type UpdateConfirmChangesModalProps = {
4
- setting: StepSetting;
5
- onClose: (doSwitch: boolean) => void;
6
- };
7
- declare const UpdateConfirmChangesModal: ({ setting, onClose }: UpdateConfirmChangesModalProps) => React.JSX.Element;
8
- export default UpdateConfirmChangesModal;
9
- //# sourceMappingURL=UpdateConfirmChangesModal.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"UpdateConfirmChangesModal.d.ts","sourceRoot":"","sources":["../../../../../../src/components/Fleet/CreateFleet/steps/UpdateConfirmChangesModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAM/B,MAAM,MAAM,WAAW,GAAG,cAAc,GAAG,kBAAkB,GAAG,iBAAiB,GAAG,mBAAmB,CAAC;AAExG,KAAK,8BAA8B,GAAG;IACpC,OAAO,EAAE,WAAW,CAAC;IACrB,OAAO,EAAE,CAAC,QAAQ,EAAE,OAAO,KAAK,IAAI,CAAC;CACtC,CAAC;AA0CF,QAAA,MAAM,yBAAyB,yBAA0B,8BAA8B,sBAwCtF,CAAC;AAEF,eAAe,yBAAyB,CAAC"}
@@ -1,61 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const React = tslib_1.__importStar(require("react"));
5
- const react_core_1 = require("@patternfly/react-core");
6
- const useTranslation_1 = require("../../../../hooks/useTranslation");
7
- const getModalContent = (setting, t) => {
8
- switch (setting) {
9
- case 'all-settings':
10
- return {
11
- title: t('Switch to basic update configuration?'),
12
- primaryAction: t('Switch to basic configurations'),
13
- question: t('Are you sure you want to switch to basic update configurations?'),
14
- result: t('If you confirm, all advanced configurations will be lost.'),
15
- };
16
- case 'rollout-policies': {
17
- const title = t("Don't use rollout policies configurations");
18
- return {
19
- title,
20
- primaryAction: title,
21
- question: t('Are you sure you want to remove the rollout policies configurations?'),
22
- result: t('If you confirm, all rollout policies configurations will be lost.'),
23
- };
24
- }
25
- case 'disruption-budget': {
26
- const title = t("Don't use disruption budget configurations");
27
- return {
28
- title,
29
- primaryAction: title,
30
- question: t('Are you sure you want to remove the disruption budget configurations?'),
31
- result: t('If you confirm, all disruption budget configurations will be lost.'),
32
- };
33
- }
34
- case 'update-policies': {
35
- const title = t("Don't use update policies");
36
- return {
37
- title,
38
- primaryAction: title,
39
- question: t('Are you sure you want to remove the update policy configurations?'),
40
- result: t('If you confirm, all update policy configurations will be lost.'),
41
- };
42
- }
43
- }
44
- };
45
- const UpdateConfirmChangesModal = ({ setting, onClose }) => {
46
- const { t } = (0, useTranslation_1.useTranslation)();
47
- const modalContentProps = getModalContent(setting, t);
48
- return (React.createElement(react_core_1.Modal, { variant: setting === 'disruption-budget' ? 'medium' : 'small', title: modalContentProps.title, titleIconVariant: "warning", isOpen: true },
49
- React.createElement(react_core_1.Stack, { hasGutter: true },
50
- React.createElement(react_core_1.StackItem, null, modalContentProps.question),
51
- React.createElement(react_core_1.StackItem, null, modalContentProps.result),
52
- React.createElement(react_core_1.StackItem, null,
53
- React.createElement(react_core_1.Button, { key: "confirm", variant: "primary", tabIndex: 0, onClick: () => {
54
- onClose(true);
55
- } }, modalContentProps.primaryAction),
56
- React.createElement(react_core_1.Button, { key: "cancel", variant: "link", tabIndex: 0, onClick: () => {
57
- onClose(false);
58
- } }, t('Cancel'))))));
59
- };
60
- exports.default = UpdateConfirmChangesModal;
61
- //# sourceMappingURL=UpdateConfirmChangesModal.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"UpdateConfirmChangesModal.js","sourceRoot":"","sources":["../../../../../../src/components/Fleet/CreateFleet/steps/UpdateConfirmChangesModal.tsx"],"names":[],"mappings":";;;AAAA,qDAA+B;AAC/B,uDAAyE;AAGzE,qEAAkE;AASlE,MAAM,eAAe,GAAG,CAAC,OAAoB,EAAE,CAAY,EAAE,EAAE;IAC7D,QAAQ,OAAO,EAAE,CAAC;QAChB,KAAK,cAAc;YACjB,OAAO;gBACL,KAAK,EAAE,CAAC,CAAC,uCAAuC,CAAC;gBACjD,aAAa,EAAE,CAAC,CAAC,gCAAgC,CAAC;gBAClD,QAAQ,EAAE,CAAC,CAAC,iEAAiE,CAAC;gBAC9E,MAAM,EAAE,CAAC,CAAC,2DAA2D,CAAC;aACvE,CAAC;QACJ,KAAK,kBAAkB,CAAC,CAAC,CAAC;YACxB,MAAM,KAAK,GAAG,CAAC,CAAC,2CAA2C,CAAC,CAAC;YAC7D,OAAO;gBACL,KAAK;gBACL,aAAa,EAAE,KAAK;gBACpB,QAAQ,EAAE,CAAC,CAAC,sEAAsE,CAAC;gBACnF,MAAM,EAAE,CAAC,CAAC,mEAAmE,CAAC;aAC/E,CAAC;QACJ,CAAC;QAED,KAAK,mBAAmB,CAAC,CAAC,CAAC;YACzB,MAAM,KAAK,GAAG,CAAC,CAAC,4CAA4C,CAAC,CAAC;YA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AC,mBAAM,IACL,GAAG,EAAC,QAAQ,EACZ,OAAO,EAAC,MAAM,EACd,QAAQ,EAAE,CAAC,EACX,OAAO,EAAE,GAAG,EAAE;wBACZ,OAAO,CAAC,KAAK,CAAC,CAAC;oBACjB,CAAC,IAEA,CAAC,CAAC,QAAQ,CAAC,CACL,CACC,CACN,CACF,CACT,CAAC;AACJ,CAAC,CAAC;AAEF,kBAAe,yBAAyB,CAAC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"FleetDetails.d.ts","sourceRoot":"","sources":["../../../../../src/components/Fleet/FleetDetails/FleetDetails.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AA4G1B,QAAA,MAAM,2BAA2B,yBAOhC,CAAC;AAEF,eAAe,2BAA2B,CAAC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"FleetDetails.js","sourceRoot":"","sources":["../../../../../src/components/Fleet/FleetDetails/FleetDetails.tsx"],"names":[],"mappings":";;;AAAA,0DAA0B;AAC1B,uDAAoE;AAGpE,8EAA2E;AAC3E,wFAAwD;AACxD,sGAAsE;AACtE,wFAAwD;AACxD,kEAA+D;AAC/D,4DAAgE;AAChE,gEAA6D;AAC7D,oGAAoE;AACpE,oEAAiE;AACjE,8CAAqD;AACrD,mGAAmE;AAEnE,MAAM,YAAY,GAAG,GAAG,EAAE;;IACxB,MAAM,EAAE,CAAC,EAAE,GAAG,IAAA,+BAAc,GAAE,CAAC;IAE/B,MAAM,EACJ,MAAM,EAAE,EAAE,SAAS,EAAE,GACtB,GAAG,IAAA,6BAAa,GAAE,CAAC;IACpB,MAAM,EAAE,OAAO,EAAE,GAAG,SAAS,EAAyB,CAAC;IACvD,MAAM,CAAC,KAAK,EAAE,SAAS,EAAE,KAAK,EAAE,OAAO,CAAC,GAAG,IAAA,2CAAoB,EAAkB;QAC/E,QAAQ,EAAE,UAAU,OAAO,yBAAyB;KACrD,CAAC,CAAC;IACH,MAAM,CAAC,iBAAiB,EAAE,oB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C,CAAC;oBAC7B,CAAC,EACD,cAAc,EAAE,SAAS,EACzB,YAAY,EACV,SAAS;wBACP,CAAC,CAAC;4BACE,OAAO,EAAE,CAAC,CACR,yLAAyL,CAC1L;yBACF;wBACH,CAAC,CAAC,SAAS,IAGd,CAAC,CAAC,cAAc,CAAC,CACL,CAChB,CACY,CACI,CACtB,IAGF,KAAK,IAAI,CACR;QACE,8BAAC,6BAAmB,IAAC,KAAK,EAAE,KAAK,GAAI;QACpC,iBAAiB,IAAI,CACpB,8BAAC,0BAAgB,IACf,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,CAAC,UAAoB,EAAE,EAAE;gBAChC,IAAI,UAAU,EAAE,CAAC;oBACf,OAAO,EAAE,CAAC;oBACV,QAAQ,CAAC,mBAAK,CAAC,MAAM,CAAC,CAAC;gBACzB,CAAC;gBACD,oBAAoB,CAAC,KAAK,CAAC,CAAC;YAC9B,CAAC,GACD,CACH,CACA,CACJ,CACW,CACf,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,2BAA2B,GAAG,GAAG,EAAE;IACvC,MAAM,CAAC,OAAO,EAAE,OAAO,CAAC,GAAG,IAAA,iCAAe,EAAC,eAAQ,CAAC,KAAK,EAAE,WAAI,CAAC,GAAG,CAAC,CAAC;IACrE,OAAO,CACL,8BAAC,6BAAmB,IAAC,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO;QACrD,8BAAC,YAAY,OAAG,CACI,CACvB,CAAC;AACJ,CAAC,CAAC;AAEF,kBAAe,2BAA2B,CAAC"}
@@ -1,9 +0,0 @@
1
- .fctl-labels-view__collapsed {
2
- /* Set a maximum width on larger breakpoints */
3
- @media (min-width: 769px) {
4
- max-width: 400px;
5
- }
6
- }
7
-
8
-
9
-
@@ -1,7 +0,0 @@
1
- export declare const CREATING_APPLICATIONS_LINK = "https://github.com/flightctl/flightctl/blob/main/docs/user/managing-devices.md#creating-applications";
2
- export declare const USING_TEMPLATE_VARIABLES_LINK = "https://github.com/flightctl/flightctl/blob/main/docs/user/managing-fleets.md#defining-device-templates";
3
- export declare const ADDING_NEW_DEVICES_LINK = "https://github.com/flightctl/flightctl/blob/main/docs/user/getting-started.md#building-a-bootable-container-image-including-the-flight-control-agent";
4
- export declare const CREATE_ACM_REPOSITORY = "https://github.com/flightctl/flightctl/blob/main/docs/user/registering-microshift-devices-acm.md#creating-the-acm-registration-repository";
5
- export declare const DEMO_REPOSITORY_URL = "https://github.com/flightctl/flightctl-demos";
6
- export declare const TECH_PREVIEW_LEVEL_LINK = "https://access.redhat.com/support/offerings/techpreview";
7
- //# sourceMappingURL=links.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"links.d.ts","sourceRoot":"","sources":["../../src/links.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,0BAA0B,yGAAsE,CAAC;AAE9G,eAAO,MAAM,6BAA6B,4GAAyE,CAAC;AAEpH,eAAO,MAAM,uBAAuB,yJAAsH,CAAC;AAE3J,eAAO,MAAM,qBAAqB,8IAA2G,CAAC;AAG9I,eAAO,MAAM,mBAAmB,iDAAiD,CAAC;AAGlF,eAAO,MAAM,uBAAuB,4DAA4D,CAAC"}
package/dist/src/links.js DELETED
@@ -1,14 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.TECH_PREVIEW_LEVEL_LINK = exports.DEMO_REPOSITORY_URL = exports.CREATE_ACM_REPOSITORY = exports.ADDING_NEW_DEVICES_LINK = exports.USING_TEMPLATE_VARIABLES_LINK = exports.CREATING_APPLICATIONS_LINK = void 0;
4
- const baseDocsRepoUrl = 'https://github.com/flightctl/flightctl/blob/main/docs';
5
- // Links to the fLightctl upstream docs
6
- exports.CREATING_APPLICATIONS_LINK = `${baseDocsRepoUrl}/user/managing-devices.md#creating-applications`;
7
- exports.USING_TEMPLATE_VARIABLES_LINK = `${baseDocsRepoUrl}/user/managing-fleets.md#defining-device-templates`;
8
- exports.ADDING_NEW_DEVICES_LINK = `${baseDocsRepoUrl}/user/getting-started.md#building-a-bootable-container-image-including-the-flight-control-agent`;
9
- exports.CREATE_ACM_REPOSITORY = `${baseDocsRepoUrl}/user/registering-microshift-devices-acm.md#creating-the-acm-registration-repository`;
10
- // Links to other flightctl upstream resources
11
- exports.DEMO_REPOSITORY_URL = 'https://github.com/flightctl/flightctl-demos';
12
- // Links to general Red Hat docs
13
- exports.TECH_PREVIEW_LEVEL_LINK = 'https://access.redhat.com/support/offerings/techpreview';
14
- //# sourceMappingURL=links.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"links.js","sourceRoot":"","sources":["../../src/links.ts"],"names":[],"mappings":";;;AAAA,MAAM,eAAe,GAAG,uDAAuD,CAAC;AAEhF,uCAAuC;AAC1B,QAAA,0BAA0B,GAAG,GAAG,eAAe,iDAAiD,CAAC;AAEjG,QAAA,6BAA6B,GAAG,GAAG,eAAe,oDAAoD,CAAC;AAEvG,QAAA,uBAAuB,GAAG,GAAG,eAAe,iGAAiG,CAAC;AAE9I,QAAA,qBAAqB,GAAG,GAAG,eAAe,sFAAsF,CAAC;AAE9I,8CAA8C;AACjC,QAAA,mBAAmB,GAAG,8CAA8C,CAAC;AAElF,gCAAgC;AACnB,QAAA,uBAAuB,GAAG,yDAAyD,CAAC"}
@@ -1,3 +0,0 @@
1
- .fctl-device-status-debug__actions {
2
- text-align: right;
3
- }